https://issues.dlang.org/show_bug.cgi?id=15908

greensunn...@gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |greensunn...@gmail.com

--- Comment #2 from greensunn...@gmail.com ---
Uranuz from D.learn also hit this bug - in his/her case for structs:

http://forum.dlang.org/post/noq45h$lgu$1...@digitalmars.com


struct A
{
    import std.algorithm: map;
    import std.array: array;
    import std.typecons: tuple;


    static immutable aaa = [
        tuple("1", "one"),
        tuple("2", "two"),
        tuple("3", "three")
    ];

    static immutable bbb = aaa.map!( a => a[0] ).array;

}

void main()
{
    A a = A();
}

//---------

Compilation output:
/opt/compilers/dmd2/include/std/algorithm/iteration.d(455): Error:
this.__lambda6 has no value

> I'm pretty sure it's ctfe specific.

On DMD nightly you even get a better error message saying that am error during
CTFE happened :/

--

Reply via email to