[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2021-12-03 Thread pinskia at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Andrew Pinski  changed:

   What|Removed |Added

   Target Milestone|--- |9.2

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-06-14 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #5 from Marek Polacek  ---
Still ICEs:

$ ./cc1plus -quiet 60223.C
60223.C: In substitution of ‘template void foo(A) [with T =
]’:
60223.C:7:16:   required from here
60223.C:7:16: internal compiler error: in unify, at cp/pt.c:22789
7 |   foo(A());
  |^
0xaef167 unify
/home/mpolacek/src/gcc/gcc/cp/pt.c:22789
0xaed61d unify
/home/mpolacek/src/gcc/gcc/cp/pt.c:22553
0xae91d1 try_class_unification
/home/mpolacek/src/gcc/gcc/cp/pt.c:21548
0xaeda43 unify
/home/mpolacek/src/gcc/gcc/cp/pt.c:22590
0xae68b1 unify_one_argument
/home/mpolacek/src/gcc/gcc/cp/pt.c:20781
0xae6d48 type_unification_real
/home/mpolacek/src/gcc/gcc/cp/pt.c:20900
0xae503f fn_type_unification(tree_node*, tree_node*, tree_node*, tree_node*
const*, unsigned int, tree_node*, unification_kind_t, int, conversion**, bool,
bool)
/home/mpolacek/src/gcc/gcc/cp/pt.c:20280
0x85a35a add_template_candidate_real
/home/mpolacek/src/gcc/gcc/cp/call.c:3315
0x85a8ec add_template_candidate
/home/mpolacek/src/gcc/gcc/cp/call.c:3400
0x862c22 add_candidates
/home/mpolacek/src/gcc/gcc/cp/call.c:5724
0x85da1f perform_overload_resolution
/home/mpolacek/src/gcc/gcc/cp/call.c:4396
0x85dc90 build_new_function_call(tree_node*, vec**, int)
/home/mpolacek/src/gcc/gcc/cp/call.c:4470
0xb31529 finish_call_expr(tree_node*, vec**, bool,
bool, int)
/home/mpolacek/src/gcc/gcc/cp/semantics.c:2584
0xa28a9c cp_parser_postfix_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:7375
0xa2b334 cp_parser_unary_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:8461
0xa2c78e cp_parser_cast_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:9346
0xa2c87b cp_parser_binary_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:9449
0xa2d639 cp_parser_assignment_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:9747
0xa2d9c4 cp_parser_expression
/home/mpolacek/src/gcc/gcc/cp/parser.c:9914
0xa313ff cp_parser_expression_statement
/home/mpolacek/src/gcc/gcc/cp/parser.c:11515
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See  for instructions.

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-06-17 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Marek Polacek  changed:

   What|Removed |Added

 Status|NEW |ASSIGNED
   Assignee|unassigned at gcc dot gnu.org  |mpolacek at gcc dot 
gnu.org

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-06-18 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Marek Polacek  changed:

   What|Removed |Added

   Keywords||patch

--- Comment #6 from Marek Polacek  ---
https://gcc.gnu.org/ml/gcc-patches/2019-06/msg01054.html

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-06-21 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #7 from Marek Polacek  ---
Author: mpolacek
Date: Fri Jun 21 20:32:06 2019
New Revision: 272571

URL: https://gcc.gnu.org/viewcvs?rev=272571&root=gcc&view=rev
Log:
PR c++/60223 - ICE with T{} in non-deduced context.
* pt.c (unify): Allow COMPOUND_LITERAL_P in a non-deduced context.

* g++.dg/cpp0x/nondeduced1.C: New test.
* g++.dg/cpp0x/nondeduced2.C: New test.
* g++.dg/cpp0x/nondeduced3.C: New test.
* g++.dg/cpp0x/nondeduced4.C: New test.

Added:
trunk/gcc/testsuite/g++.dg/cpp0x/nondeduced1.C
trunk/gcc/testsuite/g++.dg/cpp0x/nondeduced2.C
trunk/gcc/testsuite/g++.dg/cpp0x/nondeduced3.C
trunk/gcc/testsuite/g++.dg/cpp0x/nondeduced4.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/pt.c
trunk/gcc/testsuite/ChangeLog

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-06-21 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #8 from Marek Polacek  ---
Fixed on trunk but I'll leave it open because I want to fix it for 9.2 also.

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-07-01 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #9 from Marek Polacek  ---
Author: mpolacek
Date: Tue Jul  2 00:22:37 2019
New Revision: 272917

URL: https://gcc.gnu.org/viewcvs?rev=272917&root=gcc&view=rev
Log:
PR c++/60223 - ICE with T{} in non-deduced context.
* pt.c (unify): Allow COMPOUND_LITERAL_P in a non-deduced context.

* g++.dg/cpp0x/nondeduced1.C: New test.
* g++.dg/cpp0x/nondeduced2.C: New test.
* g++.dg/cpp0x/nondeduced3.C: New test.
* g++.dg/cpp0x/nondeduced4.C: New test.

Added:
branches/gcc-9-branch/gcc/testsuite/g++.dg/cpp0x/nondeduced1.C
branches/gcc-9-branch/gcc/testsuite/g++.dg/cpp0x/nondeduced2.C
branches/gcc-9-branch/gcc/testsuite/g++.dg/cpp0x/nondeduced3.C
branches/gcc-9-branch/gcc/testsuite/g++.dg/cpp0x/nondeduced4.C
Modified:
branches/gcc-9-branch/gcc/cp/ChangeLog
branches/gcc-9-branch/gcc/cp/pt.c

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2019-07-01 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Marek Polacek  changed:

   What|Removed |Added

 Status|ASSIGNED|RESOLVED
 Resolution|--- |FIXED

--- Comment #10 from Marek Polacek  ---
Fixed.

[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2014-02-16 Thread glisse at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Marc Glisse  changed:

   What|Removed |Added

 Status|UNCONFIRMED |NEW
   Last reconfirmed||2014-02-16
 Ever confirmed|0   |1


[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2014-02-18 Thread mpolacek at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

Marek Polacek  changed:

   What|Removed |Added

 CC||mpolacek at gcc dot gnu.org

--- Comment #1 from Marek Polacek  ---
Started with r180707.


[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2014-03-18 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #2 from Paolo Carlini  ---
Marek, are you sure about r180707 ?!? It's supposed to be only about command
line options names... Please confirm and in case CC Jason.


[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2014-03-18 Thread mpolacek at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #3 from Marek Polacek  ---
Ah, no, that's bogus, with -std=c++0x it ICEs even before that revision. 
Re-bisecting...


[Bug c++/60223] [c++11] ICE with C++11-style default template parameter

2014-03-18 Thread mpolacek at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60223

--- Comment #4 from Marek Polacek  ---
So, started with r166167.  Before that I see:
$ ./cc1plus-166166 -std=c++0x -quiet ~/x.C
/home/polacek/x.C: In function ‘void bar()’:
/home/polacek/x.C:7:13: error: ‘'\000'’ is not a valid template argument for
type ‘char’ because it is a non-constant expression