[Issue 19920] New: __trait(parent, ...) broken with extern(C++, "ns") nested in scopes

d-bugmail at puremagic.com d-bugmail at puremagic.com
Thu May 30 00:47:40 UTC 2019


          Issue ID: 19920
           Summary: __trait(parent, ...) broken with extern(C++,"ns")
                    nested in scopes
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Severity: major
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: iamthewilsonator at hotmail.com

struct Foo
    extern(C++, "namespace")
        static void bar();

alias Alias(alias a) = a;
alias Alias(T) = T;

static assert(is(Alias!(__traits(parent, bar)) == Foo));

somehow passes

static assert(is(Alias!(__traits(parent, Foo.bar)) == Foo));

fails, as does


See also https://github.com/dlang/dmd/pull/9912


More information about the Digitalmars-d-bugs mailing list