[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-14 Thread nathan at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

Nathan Sidwell  changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED

--- Comment #7 from Nathan Sidwell  ---
fixed on trunk & gcc-6 branch

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-14 Thread nathan at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

--- Comment #6 from Nathan Sidwell  ---
Author: nathan
Date: Wed Dec 14 17:23:06 2016
New Revision: 243660

URL: https://gcc.gnu.org/viewcvs?rev=243660=gcc=rev
Log:
PR c++/78701
* pt.c (type_unification_real): Check tsubst arg doesn't have
remaining template parms before converting it.

PR c++/78701
* g++.dg/cpp0x/pr78701.C: New.

Added:
branches/gcc-6-branch/gcc/testsuite/g++.dg/cpp0x/pr78701.C
Modified:
branches/gcc-6-branch/gcc/cp/ChangeLog
branches/gcc-6-branch/gcc/cp/pt.c
branches/gcc-6-branch/gcc/testsuite/ChangeLog

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-14 Thread nathan at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

--- Comment #5 from Nathan Sidwell  ---
Author: nathan
Date: Wed Dec 14 16:45:33 2016
New Revision: 243657

URL: https://gcc.gnu.org/viewcvs?rev=243657=gcc=rev
Log:
PR c++/78701
* pt.c (type_unification_real): Check tsubst arg doesn't have
remaining template parms before converting it.

PR c++/78701
* g++.dg/cpp0x/pr78701.C: New.

Added:
trunk/gcc/testsuite/g++.dg/cpp0x/pr78701.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/pt.c
trunk/gcc/testsuite/ChangeLog

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-12 Thread jakub at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

Jakub Jelinek  changed:

   What|Removed |Added

 CC||jakub at gcc dot gnu.org

--- Comment #4 from Jakub Jelinek  ---
Somehow convert_template_argument is called with TEMPLATE_PARM_INDEX, even when
processing_template_decl is 0, which results in it not to be considered
dependent, while the constexpr.c code doesn't expect it to appear.

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-09 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

Richard Biener  changed:

   What|Removed |Added

   Priority|P3  |P2

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-09 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

Richard Biener  changed:

   What|Removed |Added

   Target Milestone|--- |6.3

[Bug c++/78701] [6/7 Regression] ICE: unexpected expression N of kind template_parm_index

2016-12-06 Thread vince.rev at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

--- Comment #3 from Vincent  ---
I am compiling with:
g++ test_bug.cpp -o test_bug
g++ -std=c++11 test_bug.cpp -o test_bug
g++ -std=c++14 test_bug.cpp -o test_bug
and it fails in the 3 cases.

[Bug c++/78701] [6/7 Regression]ICE: unexpected expression N of kind template_parm_index

2016-12-06 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78701

Martin Liška  changed:

   What|Removed |Added

   Keywords||ice-on-valid-code,
   ||rejects-valid
 Status|UNCONFIRMED |NEW
   Last reconfirmed||2016-12-06
 CC||marxin at gcc dot gnu.org
Summary|Internal compiler error:|[6/7 Regression]ICE:
   |unexpected expression N of  |unexpected expression N of
   |kind template_parm_index|kind template_parm_index
 Ever confirmed|0   |1

--- Comment #2 from Martin Liška  ---
Both snippets started to be rejected (ICE) with r223301.
One has to use -std=c++11.