foo => "bar" key/value literals in D!
Daniel N via Digitalmars-d-announce
digitalmars-d-announce at puremagic.com
Wed May 25 04:57:48 PDT 2016
On Wednesday, 25 May 2016 at 11:22:41 UTC, Jacob Carlborg wrote:
> On 2016-05-25 11:24, Daniel N wrote:
>
> ParameterIdentifierTuple can hopefully be updated to take
> advantage of this feature when it's available in compiler
> without requiring to change the API of ParameterIdentifierTuple.
>
> [1] https://github.com/dlang/dmd/pull/5201
Issue9608 is good too, but insufficient.
import std.traits;
static assert(__traits(isTemplate, a => 0));
static assert(!__traits(isTemplate, (int a) => 0));
The 2nd case can't be solved by 9608 since it's about
introspecting templates and "(int a) => 0)" is no template.
More information about the Digitalmars-d-announce
mailing list