String lambdas
deadalnix via Digitalmars-d
digitalmars-d at puremagic.com
Wed Apr 27 14:21:30 PDT 2016
On Tuesday, 26 April 2016 at 17:58:22 UTC, Andrei Alexandrescu
wrote:
> https://github.com/dlang/phobos/pull/3882
>
> I just closed with some regret a nice piece of engineering.
> Please comment if you think string lambdas have a lot of
> unexploited potential.
>
> One thing we really need in order to 100% replace string
> lambdas with lambdas is function equivalence. Right now we're
> in the odd situation that SomeTemplate!((a, b) => a < b) has
> distinct types, one per instantiation.
>
>
> Andrei
This can be worked around by defining a less function and using
it here. This, however, runs into some subtleties because
functions and functions aren't the same thing in D (Confusing ?
You bet it is !).
More information about the Digitalmars-d
mailing list