https://bugs.llvm.org/show_bug.cgi?id=42365

            Bug ID: 42365
           Summary: using declaration issue in nested inheritance context
           Product: clang
           Version: 8.0
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: [email protected]
          Reporter: [email protected]
                CC: [email protected], [email protected],
                    [email protected], [email protected],
                    [email protected]

The following code does not compile with clang 8:

struct Bar
{
  struct EmptyBar {};

  void test(EmptyBar) const {}
};

template<typename TYPE>
struct Foo : TYPE
{
  struct Derived;

  struct EmptyFoo {};

  using TYPE::test;

  void test(EmptyFoo) const {}
};

template<typename TYPE>
struct Foo<TYPE>::Derived : Foo<TYPE>
{
  struct EmptyDerived {};

  using Foo<TYPE>::test;

  void test(EmptyDerived) const {}
};

int main()
{
  Bar::EmptyBar empty;

  Foo<Bar>::Derived obj;

  obj.test(empty);

  return 0;
}

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to