"fold": a replacement for "reduce"

Meta jared771 at gmail.com
Thu Mar 27 17:41:51 PDT 2014


On Thursday, 27 March 2014 at 22:33:50 UTC, Timon Gehr wrote:
> It doesn't make sense at all. It is an arbitrary limitation. 
> The rule is simple though: One can only alias things that 
> syntactically look like they might be types. This is why the 
> following triviality is way more useful than it should be:
>
> alias Id(alias a)=a;
>
> alias fun = Id!(a=>a); // ok!

You can tell me that function literals look like types, but I 
won't believe you.


More information about the Digitalmars-d mailing list