re PR c++/47511 ([C++0x] ICE: unexpected ast of kind template_decl in potential_constant_expression_1, at cp/semantics.c:7711)
PR c++/47511 * semantics.c (potential_constant_expression_1): Handle TEMPLATE_DECL. From-SVN: r170005
This commit is contained in:
parent
72602cd16b
commit
5b883ca61c
|
@ -1,3 +1,8 @@
|
|||
2011-02-09 Jason Merrill <jason@redhat.com>
|
||||
|
||||
PR c++/47511
|
||||
* semantics.c (potential_constant_expression_1): Handle TEMPLATE_DECL.
|
||||
|
||||
2011-02-03 Dodji Seketeli <dodji@redhat.com>
|
||||
|
||||
PR c++/47398
|
||||
|
|
|
@ -7263,6 +7263,7 @@ potential_constant_expression_1 (tree t, bool want_rval, tsubst_flags_t flags)
|
|||
{
|
||||
case FUNCTION_DECL:
|
||||
case BASELINK:
|
||||
case TEMPLATE_DECL:
|
||||
case OVERLOAD:
|
||||
case TEMPLATE_ID_EXPR:
|
||||
case LABEL_DECL:
|
||||
|
|
|
@ -1,3 +1,10 @@
|
|||
2011-02-09 Jason Merrill <jason@redhat.com>
|
||||
|
||||
* g++.dg/cpp0x/regress: New directory.
|
||||
* g++.dg/cpp0x/constexpr-regress1.C: Move to regress/regress1.C.
|
||||
* g++.dg/cpp0x/constexpr-regress2.C: Move to regress/regress2.C.
|
||||
* g++.dg/cpp0x/regress/regress3.C: New.
|
||||
|
||||
2011-02-10 Richard Guenther <rguenther@suse.de>
|
||||
|
||||
PR tree-optimization/47677
|
||||
|
|
|
@ -0,0 +1,3 @@
|
|||
This directory contains tests that were passing in C++98 mode but failing
|
||||
in C++0x mode; it should be replaced by an improvement to the test harness
|
||||
to run all tests in both modes.
|
|
@ -0,0 +1,13 @@
|
|||
// PR c++/47511
|
||||
// { dg-options -std=c++0x }
|
||||
|
||||
namespace N {
|
||||
template <typename T> bool g( T ) {
|
||||
return true;
|
||||
}
|
||||
struct A { };
|
||||
}
|
||||
template <class T> void f(const T&) {
|
||||
N::A x;
|
||||
g(x) ;
|
||||
}
|
Loading…
Reference in New Issue