From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:37346) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SeubR-0006ZI-Cq for qemu-devel@nongnu.org; Wed, 13 Jun 2012 16:55:46 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SeubP-00088U-Gz for qemu-devel@nongnu.org; Wed, 13 Jun 2012 16:55:44 -0400 Received: from e39.co.us.ibm.com ([32.97.110.160]:36009) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SeubP-00088E-Av for qemu-devel@nongnu.org; Wed, 13 Jun 2012 16:55:43 -0400 Received: from /spool/local by e39.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 13 Jun 2012 14:55:39 -0600 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by d03dlp03.boulder.ibm.com (Postfix) with ESMTP id 656C619D8053 for ; Wed, 13 Jun 2012 20:55:35 +0000 (WET) Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id q5DKtFfv205878 for ; Wed, 13 Jun 2012 14:55:29 -0600 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id q5DKtDkm017173 for ; Wed, 13 Jun 2012 14:55:13 -0600 From: Anthony Liguori Date: Wed, 13 Jun 2012 15:54:59 -0500 Message-Id: <1339620902-4481-1-git-send-email-aliguori@us.ibm.com> Subject: [Qemu-devel] [PATCH 0/3] qom: refactor Interfaces List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: "Peter A. G. Crosthwaite" , Paolo Bonzini , Andreas Faerber The interface implementation was pretty busted. The way it created Objects for each interface was extremely clumbsy and brittle. This is a new implementation that does something quite a bit more natural. It simply modifies classes such that they can affectively have more than one super class. Interfaces never get instantiated. Instead an object's class just refers to its parent class and it's implemented interfaces. This should solve the issues Peter's run into and also eliminate the recursive call to object_new() (its no longer necessary to allocate anything when creating an object). This also comes with a test case for object.