[LLVMbugs] [Bug 16293] New: class template friend declarations raise an error where EDG and g++ don't

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Mon Jun 10 23:39:40 PDT 2013


http://llvm.org/bugs/show_bug.cgi?id=16293

            Bug ID: 16293
           Summary: class template friend declarations raise an error
                    where EDG and g++ don't
           Product: clang
           Version: unspecified
          Hardware: PC
                OS: All
            Status: NEW
          Severity: normal
          Priority: P
         Component: C++
          Assignee: unassignedclangbugs at nondot.org
          Reporter: david.majnemer at gmail.com
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

consider the following:

template <typename T>
class Foo {
  class Nested {
  };
};

template <typename T>
class A {
    template <typename> friend class Foo<T>::Nested;
};

clang claims: "redefinition of 'Nested' as different kind of symbol" and points
to the friend decl...

g++ and EDG has no issue with it.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20130611/82bde45c/attachment.html>


More information about the llvm-bugs mailing list