"Nick Sabalausky" <[email protected]> wrote in message 
news:[email protected]...
> "Nick" <[email protected]> wrote in message 
> news:[email protected]...
>> Coming from Andrei's work in C++ "Modern C++ Programming" I wonder how to 
>> implement many of those patterns in D?
>>
>> In C++ I would work with type lists and use lots of multiple inheritance 
>> and templates to get the magic I need.
>>
>
> I abandoned C++ about 10 years ago so I don't know anything about the 
> patterns you're talking about, but:
>
>> D lacks MI,
>
> Replaced by either mixins or interfaces, depending on what you're trying 
> to do.
>

Oh, and also "alias this" which, as explained in Andrei's book "The D 
Programming Language" can be a very useful alternative to MI, particularly 
when combined with nested classes. "alias this" is also good for subtyping 
structs, even though structs still aren't polymorphic.

Like Jason said, if you have specific examples of idioms, we can translate 
to D for you.


Reply via email to