I wish I could use D for everything

Steven Schveighoffer schveiguy at yahoo.com
Thu Apr 30 04:53:33 PDT 2009


On Thu, 30 Apr 2009 06:50:12 -0400, Christopher Wright  
<dhasenan at gmail.com> wrote:

> Steven Schveighoffer wrote:
>> I can't wait for D to take over the world, so I no longer have to write  
>> in this horrid language ;)
>
> C# is pretty reasonable. I see a fair number of things in recent  
> versions that have been in D for a while, and some other vaguely neat  
> things that D doesn't have on occasion.

I'm still stuck on 2.0, but that's mostly because I don't want to port to  
3.0, so maybe C# has gotten better, but you identified some of the same  
views I have.

>
> My main complaint with C# is a lack of interesting template  
> capabilities. For example, I find that I often need two classes that are  
> extremely similar with some minor exceptions, and in D I could just use  
> a simple template, whereas in C# I have to duplicate the entire class.

Yes, and generics are noticably inferior.  They aren't even close to  
templates.  I hate how you have to specify the base class in order to use  
any methods on a parameterized type.

I was surprised to learn it had some sort of equivalent to IFTI.

> On the other hand, my main complaint with D is the lack of reflection,  
> including attributes. I rarely use reflection in C#, but I make  
> extensive use of libraries that use reflection a lot (Rhino Mocks, the  
> Castle project, NHibernate...)

Yes, I use reflection in some of my code, and it definitely has to come to  
D sometime.  At least if I wanted to port my current project to D it would  
have to ;)

-Steve



More information about the Digitalmars-d mailing list