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

          Issue ID: 19706
           Summary: Attribute inference in struct fails
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: [email protected]
          Reporter: [email protected]

In this code

    struct S
    {
        static int fImpl(Ret)() { return Ret.init; }

        // tells us: `fImpl!int` is @system
        pragma(msg, __traits(getFunctionAttributes, fImpl!int)); 
    }

the function attributes should be @safe, pure, nothrow and @nogc.

--

Reply via email to