[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [RFC v0 5/8] object: make interfaces concrete

From: Anthony Liguori
Subject: Re: [Qemu-devel] [RFC v0 5/8] object: make interfaces concrete
Date: Wed, 13 Jun 2012 08:36:19 -0500
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20120329 Thunderbird/11.0.1

On 06/13/2012 08:33 AM, Paolo Bonzini wrote:
Il 13/06/2012 15:30, Anthony Liguori ha scritto:
Anyway, I don't like the idea of making interfaces concrete.  That means
that a user could directly instantiate an interface which doesn't make a
lot of sense.

Concrete doesn't mean "instantiatable by the user".  It means
"instantiatable period".

Interfaces are not supposed to be instantiatable by anyone. The fact that object_new() is used to create the interface is an internal implementation detail.

Interfaces are stateless and by definition, never have an implementation on their own. So object_new() of an interface type directly results in a useless object.


Anthony Liguori


reply via email to

[Prev in Thread] Current Thread [Next in Thread]