Reducing template constraint verbosity? [was Re: Slides from my ACCU Silicon Valley talk]

spir denis.spir at gmail.com
Wed Dec 15 00:04:17 PST 2010


On Tue, 14 Dec 2010 13:57:43 -0600
Andrei Alexandrescu <SeeWebsiteForEmail at erdani.org> wrote:

> > Imagine now if I wanted to define a foo that worked only on my specific
> > range, I now have to go back and modify the constraints of all the other
> > functions. What if I don't have control over that module?  
> 
> It scales poorly on artificial examples. It scales well on real-world 
> examples, because those usually have disjunctive constraints.

Not sure of this. Look a the thread about "write, toString, formatValue & range interface". It seems (but I may be wrong) that input range cases where added to the (big) set of formatValue templates. If my reasoning is correct, this addition was not properly done, precisely negative constraints for mutual exclusion are missing, which leads to 2-3 bugs.

Denis
-- -- -- -- -- -- --
vit esse estrany ☣

spir.wikidot.com



More information about the Digitalmars-d mailing list