diff options
author | Jason Merrill <jason@redhat.com> | 2015-12-22 16:46:38 -0500 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2015-12-22 16:46:38 -0500 |
commit | d2889b14274f623af7022b060cd49b08ada66038 (patch) | |
tree | 82266f9e7233337816409fce56882967750604cf /gcc/testsuite | |
parent | d6dd2c8e29213be6d5f95106bcb9b2cb7cbabb48 (diff) | |
download | gcc-d2889b14274f623af7022b060cd49b08ada66038.zip gcc-d2889b14274f623af7022b060cd49b08ada66038.tar.gz gcc-d2889b14274f623af7022b060cd49b08ada66038.tar.bz2 |
re PR c++/67339 (Segfault when parsing a typename involving a template-alias)
PR c++/67339
* parser.c (cp_parser_elaborated_type_specifier): Use CLASS_TYPE_P
rather than check for RECORD_TYPE.
From-SVN: r231912
Diffstat (limited to 'gcc/testsuite')
-rw-r--r-- | gcc/testsuite/g++.dg/cpp0x/alias-decl-pmf1.C | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/cpp0x/alias-decl-pmf1.C b/gcc/testsuite/g++.dg/cpp0x/alias-decl-pmf1.C new file mode 100644 index 0000000..d0ac27d --- /dev/null +++ b/gcc/testsuite/g++.dg/cpp0x/alias-decl-pmf1.C @@ -0,0 +1,16 @@ +// PR c++/67339 +// { dg-do compile { target c++11 } } + +template < typename T> +struct A +{ + void foo(); + template < typename S, typename W > + using N = void (T::*)(S, W) const ; +}; + +template < typename T> +void A<T>::foo() +{ + typename A<T>::template N<int, int> fun = &T::out; +} |