[Mono-list] reusing interface implementation

Chris Howie cdhowie at gmail.com
Tue May 27 14:13:44 EDT 2008


On Tue, May 27, 2008 at 11:58 AM, Robert Jordan <robertj at gmx.net> wrote:
> Chris Howie wrote:
>> On Tue, May 27, 2008 at 10:32 AM, Mathias Tausig <mtausig at fsmat.at> wrote:
>>> I was afraid that it wouldn't work. Still thank you for removing the doubts.
>>> Do you know, why this doesn't work. I thought a bit about it, and couldn't
>>> find a logical reason that would prevent it.
>>
>> It's because the CLR does not allow one class to inherit from more
>> than one other class.
>
> Actually, some languages targeting the CLR do support multiple
> inheritance inside their own closed world. They have their
> own (non-standard) convention of mapping multiple class inheritance
> to CLR's single class inheritance + multiple interface inheritance
> rules.

I'm sure emulating it is possible with IL.  That doesn't mean it's a
core CLR feature though.

(And FWIW you could emulate pretty much anything with IL.  Look at
closures, for example.)

-- 
Chris Howie
http://www.chrishowie.com
http://en.wikipedia.org/wiki/User:Crazycomputers


More information about the Mono-list mailing list