concepts and interfaces
Don Clugston
dac at nospam.com.au
Tue Apr 10 15:19:46 PDT 2007
James Dennett wrote:
> Craig Black wrote:
>> This may sound a little retarded, but wouldn't making concepts obligatory
>> make generic programming more complex and hence more difficult? In my
>> opinion this may do more harm than good. A huge appeal of generic stuff in
>> D is that it's easier to work with than the C++ stuff. More powerful, yes,
>> but also easier. IMO this is very important.
>
> Concepts appear to make generic programming simpler and
> hence easier, with more meaningful diagnostics.
But I think Craig's point is valid (and interesting) -- concepts will
have a huge benefit for complicated C++ template code, but since D
templates are easier to work with already (and we have static
if/is/static assert), in D, concepts are at a totally different point on
the cost-benefit curve. Are they still worthwhile?
More information about the Digitalmars-d
mailing list