This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/51157] New: decltype/typeof of template member with default template argument confuses g++
- From: "joerg dot richter at pdv-fs dot de" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Wed, 16 Nov 2011 09:13:17 +0000
- Subject: [Bug c++/51157] New: decltype/typeof of template member with default template argument confuses g++
- Auto-submitted: auto-generated
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