Does D have too many features?

Andrej Mitrovic andrej.mitrovich at gmail.com
Sat Apr 28 12:36:58 PDT 2012


On 4/28/12, Walter Bright <newshound2 at digitalmars.com> wrote:
> What's your list?

I don't mind extra features, just as long as they're properly
documented and implemented. For example, I have absolutely no uses for
anonymous classes right now, but I know DWT2 uses them and probably
other people do use them.

Personally I find the hardest threads to to follow are the ones
discussing in/out/inout/autoref. For one thing there are compiler
bugs, but then there are misconceptions between what developers vs
documentation vs core devs say about them. And then you mix in classes
and templates into the story and it all becomes a large forest of
information that is very hard to digest.

Another feature I'm curious about is .dup/.idup. It's basically
hardcoded for a couple of types, but why not instead use UFCS and
implement .dup/.idup in std.array as a free function? Then you might
even use it for user-types by requiring a type to implement .dup/.idup
functions.

Also there's mixin templates. What exactly is the difference between
mixin templates and regular templates? We can use the mixin statement
for both types right now, so there doesn't seem to be a distinction.
For example, if you take samples from the template mixin page
(http://dlang.org/template-mixin.html) and you remove "mixin" from the
template declaration, all of the samples will continue to work. You
could remove this declaration feature right now and you probably
wouldn't break any code at all. Seems like low-hanging fruit to me.


More information about the Digitalmars-d mailing list