[LLVMbugs] [Bug 16906] New: an explicit specialization of a member template of a class template specialization should not inherit partial specializations from the class template specialization
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Thu Aug 15 16:12:13 PDT 2013
http://llvm.org/bugs/show_bug.cgi?id=16906
Bug ID: 16906
Summary: an explicit specialization of a member template of a
class template specialization should not inherit
partial specializations from the class template
specialization
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: unassignedclangbugs at nondot.org
Reporter: richard-llvm at metafoo.co.uk
CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
Classification: Unclassified
Clang rejects this valid code:
template<typename T> struct A {
template<typename U> struct B {};
template<typename U> struct B<U*> {};
};
template<> template<typename U> struct A<int>::B { typedef int type; };
A<int>::B<int*>::type x;
Here, per [temp.class.spec.mfunc](14.5.5.3)p2, A<int>::B<int*> uses the
explicit specialization of A<int>::B, not the partial specialization from A<T>,
so this code should be valid. But clang picks the partial specialization from
inside A<T> and rejects 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/20130815/3e8ea257/attachment.html>
More information about the llvm-bugs
mailing list