www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 19706] New: Attribute inference in struct fails


          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: nobody puremagic.com
          Reporter: qs.il.paperinik gmail.com

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.

Feb 27 2019