[Bug c++/51157] New: decltype/typeof of template member with default template argument confuses g++
joerg.richter@pdv-fs.de
gcc-bugzilla@gcc.gnu.org
Wed Nov 16 09:33:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51157
Bug #: 51157
Summary: decltype/typeof of template member with default
template argument confuses g++
Classification: Unclassified
Product: gcc
Version: unknown
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
AssignedTo: unassigned@gcc.gnu.org
ReportedBy: joerg.richter@pdv-fs.de
cat > t.cc << EOF
struct Key
{
typedef int Ser;
};
template <class S>
struct Shell
{
template<class T = Key>
typename T::Ser getId() const;
};
void func()
{
decltype(&Shell<int>::getId) a;
}
EOF
g++ -std=gnu++0x -c t.cc
# results in:
# '
# t.cc:13: confused by earlier errors, bailing out
# GCC version 4.6.2
More information about the Gcc-bugs
mailing list