Casts that makes no sense (!)
schveiguy at yahoo.com
Mon Mar 8 07:40:03 PST 2010
On Mon, 08 Mar 2010 10:12:53 -0500, Ary Borenszweig <ary at esperanto.org.ar>
> Steven Schveighoffer wrote:
>> On Mon, 08 Mar 2010 09:38:08 -0500, Ary Borenszweig
>> <ary at esperanto.org.ar> wrote:
>>> An instance of A can never be an A, so why the cast is allowed?
>> Aside from the typo, I agree with you there, this should never be
>> possible, because a derived class can not inherit both B and A.
> Where's the typo?
"An instance of A can never be an A"
Obviously you meant an instance of B :)
More information about the Digitalmars-d-learn