public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/105852] New: ice in instantiate_decl
@ 2022-06-05 4:49 dcb314 at hotmail dot com
2022-06-05 5:01 ` [Bug c++/105852] [13 Regression] " pinskia at gcc dot gnu.org
` (14 more replies)
0 siblings, 15 replies; 16+ messages in thread
From: dcb314 at hotmail dot com @ 2022-06-05 4:49 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Bug ID: 105852
Summary: ice in instantiate_decl
Product: gcc
Version: 12.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: dcb314 at hotmail dot com
Target Milestone: ---
Created attachment 53085
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=53085&action=edit
gzipped C++ source code
For the attached C code, recent gcc does this:
$ /home/dcb/gcc/results.20220528.asan.ubsan/bin/gcc -c -w -O1 bug469.cc
$ /home/dcb/gcc/results.20220604.asan.ubsan/bin/gcc -c -w -O1 bug469.cc
In file included from ../deps/v8/src/handles.h:8,
from ../deps/v8/src/builtins.h:9,
from ../deps/v8/src/builtins.cc:5:
../deps/v8/include/v8.h:8013:22: internal compiler error: Segmentation fault
0x1091949 crash_signal(int)
/home/dcb/gcc/working/gcc/../../trunk.git/gcc/toplev.cc:322
0x943705 tree_check(tree_node*, char const*, int, char const*, tree_code)
../../trunk.git/gcc/tree.h:3510
0x943705 instantiate_decl(tree_node*, bool, bool)
/home/dcb/gcc/working/gcc/../../trunk.git/gcc/cp/pt.cc:26483
0x95b8c5 instantiate_pending_templates(int)
/home/dcb/gcc/working/gcc/../../trunk.git/gcc/cp/pt.cc:26803
$
Seems to be broken again sometime between git hash 919822adc923b00e
and aec868578d851576.
I will have my usual go at reducing the code.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
@ 2022-06-05 5:01 ` pinskia at gcc dot gnu.org
2022-06-05 7:02 ` dcb314 at hotmail dot com
` (13 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: pinskia at gcc dot gnu.org @ 2022-06-05 5:01 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Version|12.0 |13.0
Target Milestone|--- |13.0
Summary|ice in instantiate_decl |[13 Regression] ice in
| |instantiate_decl
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
2022-06-05 5:01 ` [Bug c++/105852] [13 Regression] " pinskia at gcc dot gnu.org
@ 2022-06-05 7:02 ` dcb314 at hotmail dot com
2022-06-05 21:09 ` sam at gentoo dot org
` (12 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: dcb314 at hotmail dot com @ 2022-06-05 7:02 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #1 from David Binderman <dcb314 at hotmail dot com> ---
Reduced C++ code seems to be:
template <class> struct Local { friend Local False(int *); };
Local<int> source_map_url;
Local<int> False(int *);
void New() { False; }
Local<int> False(int *) {}
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
2022-06-05 5:01 ` [Bug c++/105852] [13 Regression] " pinskia at gcc dot gnu.org
2022-06-05 7:02 ` dcb314 at hotmail dot com
@ 2022-06-05 21:09 ` sam at gentoo dot org
2022-06-05 21:10 ` sam at gentoo dot org
` (11 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: sam at gentoo dot org @ 2022-06-05 21:09 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #2 from Sam James <sam at gentoo dot org> ---
*** Bug 105859 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (2 preceding siblings ...)
2022-06-05 21:09 ` sam at gentoo dot org
@ 2022-06-05 21:10 ` sam at gentoo dot org
2022-06-06 12:53 ` ppalka at gcc dot gnu.org
` (10 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: sam at gentoo dot org @ 2022-06-05 21:10 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #3 from Sam James <sam at gentoo dot org> ---
Thanks for reporting, beat me to it. Looks like it's same on latest 11 (11.3.1
20220602) and 12 (12.1.1 20220604) snapshots.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (3 preceding siblings ...)
2022-06-05 21:10 ` sam at gentoo dot org
@ 2022-06-06 12:53 ` ppalka at gcc dot gnu.org
2022-06-06 13:03 ` [Bug c++/105852] [11/12/13 " ppalka at gcc dot gnu.org
` (9 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: ppalka at gcc dot gnu.org @ 2022-06-06 12:53 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
Known to work| |12.1.0
CC| |jason at gcc dot gnu.org,
| |ppalka at gcc dot gnu.org
Last reconfirmed| |2022-06-06
See Also| |https://gcc.gnu.org/bugzill
| |a/show_bug.cgi?id=105761
--- Comment #4 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Started with r13-985-g284ae8b46f5eef.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (4 preceding siblings ...)
2022-06-06 12:53 ` ppalka at gcc dot gnu.org
@ 2022-06-06 13:03 ` ppalka at gcc dot gnu.org
2022-06-06 15:08 ` slyfox at gcc dot gnu.org
` (8 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: ppalka at gcc dot gnu.org @ 2022-06-06 13:03 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Known to work| |11.3.0
Known to fail| |13.0
Summary|[13 Regression] ice in |[11/12/13 Regression] ice
|instantiate_decl |in instantiate_decl
--- Comment #5 from Patrick Palka <ppalka at gcc dot gnu.org> ---
(In reply to Patrick Palka from comment #4)
> Started with r13-985-g284ae8b46f5eef.
... which was also backported to the 11 and 12 branches.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (5 preceding siblings ...)
2022-06-06 13:03 ` [Bug c++/105852] [11/12/13 " ppalka at gcc dot gnu.org
@ 2022-06-06 15:08 ` slyfox at gcc dot gnu.org
2022-06-06 22:39 ` jason at gcc dot gnu.org
` (7 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: slyfox at gcc dot gnu.org @ 2022-06-06 15:08 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Sergei Trofimovich <slyfox at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |slyfox at gcc dot gnu.org
--- Comment #6 from Sergei Trofimovich <slyfox at gcc dot gnu.org> ---
Got identical ICE on nodejs-16.15.1 on this week's gcc shapshot. Ended up
reducing to the same example as David's in #c1.
$ c++ -v
Using built-in specs.
COLLECT_GCC=/<<NIX>>/gcc-debug-13.0.0/bin/g++
COLLECT_LTO_WRAPPER=/<<NIX>>/gcc-debug-13.0.0/libexec/gcc/x86_64-unknown-linux-gnu/13.0.0/lto-wrapper
Target: x86_64-unknown-linux-gnu
Configured with:
Thread model: posix
Supported LTO compression algorithms: zlib
gcc version 13.0.0 20220605 (experimental) (GCC)
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (6 preceding siblings ...)
2022-06-06 15:08 ` slyfox at gcc dot gnu.org
@ 2022-06-06 22:39 ` jason at gcc dot gnu.org
2022-06-08 20:38 ` cvs-commit at gcc dot gnu.org
` (6 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: jason at gcc dot gnu.org @ 2022-06-06 22:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Jason Merrill <jason at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |jason at gcc dot gnu.org
Status|NEW |ASSIGNED
Priority|P3 |P1
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (7 preceding siblings ...)
2022-06-06 22:39 ` jason at gcc dot gnu.org
@ 2022-06-08 20:38 ` cvs-commit at gcc dot gnu.org
2022-06-08 20:39 ` cvs-commit at gcc dot gnu.org
` (5 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-08 20:38 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #7 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jason Merrill <jason@gcc.gnu.org>:
https://gcc.gnu.org/g:7d87790a871482e9c5142a8e885b4a5f76d197c8
commit r13-1017-g7d87790a871482e9c5142a8e885b4a5f76d197c8
Author: Jason Merrill <jason@redhat.com>
Date: Mon Jun 6 21:49:06 2022 -0400
c++: redeclared hidden friend take 2 [PR105852]
My previous patch for 105761 avoided copying DECL_TEMPLATE_INFO from a
friend to a later definition, but in this testcase we have first a
non-friend declaration and then a definition, and we need to avoid copying
in that case as well. But we do still want to set new_template_info to
avoid GC trouble.
With this change, the modules dump correctly identifies ::foo as a
non-template function in tpl-friend-2_a.C.
Along the way I noticed that the duplicate_decls handling of
DECL_UNIQUE_FRIEND_P was backwards for templates, where we don't clobber
DECL_LANG_SPECIFIC (olddecl) with DECL_LANG_SPECIFIC (newdecl) like we do
for non-templates.
PR c++/105852
PR c++/105761
gcc/cp/ChangeLog:
* decl.cc (duplicate_decls): Avoid copying template info
from non-templated friend even if newdecl isn't a definition.
Correct handling of DECL_UNIQUE_FRIEND_P on templates.
* pt.cc (non_templated_friend_p): New.
* cp-tree.h (non_templated_friend_p): Declare it.
gcc/testsuite/ChangeLog:
* g++.dg/modules/tpl-friend-2_a.C: Adjust expected dump.
* g++.dg/template/friend74.C: New test.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (8 preceding siblings ...)
2022-06-08 20:38 ` cvs-commit at gcc dot gnu.org
@ 2022-06-08 20:39 ` cvs-commit at gcc dot gnu.org
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
` (4 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-08 20:39 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #8 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jason Merrill <jason@gcc.gnu.org>:
https://gcc.gnu.org/g:e8ed26c2ac38ab1f6ed5a627d9089a9243e06a0c
commit r13-1018-ge8ed26c2ac38ab1f6ed5a627d9089a9243e06a0c
Author: Jason Merrill <jason@redhat.com>
Date: Tue Jun 7 15:52:30 2022 -0400
c++: non-templated friends [PR105852]
The previous patch for 105852 avoids copying DECL_TEMPLATE_INFO from a
non-templated friend, but it really shouldn't have it in the first place.
PR c++/105852
gcc/cp/ChangeLog:
* decl.cc (duplicate_decls): Change non-templated friend
check to an assert.
* pt.cc (tsubst_function_decl): Don't set DECL_TEMPLATE_INFO
on non-templated friends.
(tsubst_friend_function): Adjust.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (9 preceding siblings ...)
2022-06-08 20:39 ` cvs-commit at gcc dot gnu.org
@ 2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
` (3 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-08 21:31 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Jason Merrill
<jason@gcc.gnu.org>:
https://gcc.gnu.org/g:e057d454db4dcf48c22f75e57599f797d8e55baf
commit r12-8467-ge057d454db4dcf48c22f75e57599f797d8e55baf
Author: Jason Merrill <jason@redhat.com>
Date: Mon Jun 6 21:49:06 2022 -0400
c++: redeclared hidden friend take 2 [PR105852]
My previous patch for 105761 avoided copying DECL_TEMPLATE_INFO from a
friend to a later definition, but in this testcase we have first a
non-friend declaration and then a definition, and we need to avoid copying
in that case as well. But we do still want to set new_template_info to
avoid GC trouble.
With this change, the modules dump correctly identifies ::foo as a
non-template function in tpl-friend-2_a.C.
Along the way I noticed that the duplicate_decls handling of
DECL_UNIQUE_FRIEND_P was backwards for templates, where we don't clobber
DECL_LANG_SPECIFIC (olddecl) with DECL_LANG_SPECIFIC (newdecl) like we do
for non-templates.
PR c++/105852
PR c++/105761
gcc/cp/ChangeLog:
* decl.cc (duplicate_decls): Avoid copying template info
from non-templated friend even if newdecl isn't a definition.
Correct handling of DECL_UNIQUE_FRIEND_P on templates.
* pt.cc (non_templated_friend_p): New.
* cp-tree.h (non_templated_friend_p): Declare it.
gcc/testsuite/ChangeLog:
* g++.dg/modules/tpl-friend-2_a.C: Adjust expected dump.
* g++.dg/template/friend74.C: New test.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (10 preceding siblings ...)
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
@ 2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
2022-06-13 12:52 ` rguenth at gcc dot gnu.org
` (2 subsequent siblings)
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-06-08 21:31 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Jason Merrill
<jason@gcc.gnu.org>:
https://gcc.gnu.org/g:3e39a0a4b71dce674ee30fe71590b0152663b6d8
commit r11-10055-g3e39a0a4b71dce674ee30fe71590b0152663b6d8
Author: Jason Merrill <jason@redhat.com>
Date: Mon Jun 6 21:49:06 2022 -0400
c++: redeclared hidden friend take 2 [PR105852]
My previous patch for 105761 avoided copying DECL_TEMPLATE_INFO from a
friend to a later definition, but in this testcase we have first a
non-friend declaration and then a definition, and we need to avoid copying
in that case as well. But we do still want to set new_template_info to
avoid GC trouble.
With this change, the modules dump correctly identifies ::foo as a
non-template function in tpl-friend-2_a.C.
Along the way I noticed that the duplicate_decls handling of
DECL_UNIQUE_FRIEND_P was backwards for templates, where we don't clobber
DECL_LANG_SPECIFIC (olddecl) with DECL_LANG_SPECIFIC (newdecl) like we do
for non-templates.
PR c++/105852
PR c++/105761
gcc/cp/ChangeLog:
* decl.c (duplicate_decls): Avoid copying template info
from non-templated friend even if newdecl isn't a definition.
Correct handling of DECL_UNIQUE_FRIEND_P on templates.
* pt.c (non_templated_friend_p): New.
* cp-tree.h (non_templated_friend_p): Declare it.
gcc/testsuite/ChangeLog:
* g++.dg/modules/tpl-friend-2_a.C: Adjust expected dump.
* g++.dg/template/friend74.C: New test.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (11 preceding siblings ...)
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
@ 2022-06-13 12:52 ` rguenth at gcc dot gnu.org
2023-05-09 3:47 ` cvs-commit at gcc dot gnu.org
2023-05-09 3:51 ` cvs-commit at gcc dot gnu.org
14 siblings, 0 replies; 16+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-06-13 12:52 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Status|ASSIGNED |RESOLVED
--- Comment #11 from Richard Biener <rguenth at gcc dot gnu.org> ---
Fixed(?)
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (12 preceding siblings ...)
2022-06-13 12:52 ` rguenth at gcc dot gnu.org
@ 2023-05-09 3:47 ` cvs-commit at gcc dot gnu.org
2023-05-09 3:51 ` cvs-commit at gcc dot gnu.org
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-05-09 3:47 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #12 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Jason Merrill
<jason@gcc.gnu.org>:
https://gcc.gnu.org/g:0697a1a426424468b9bdf3d845237cab26ce78d7
commit r11-10751-g0697a1a426424468b9bdf3d845237cab26ce78d7
Author: Jason Merrill <jason@redhat.com>
Date: Tue Jun 7 15:52:30 2022 -0400
c++: non-templated friends [PR105852]
The previous patch for 105852 avoids copying DECL_TEMPLATE_INFO from a
non-templated friend, but it really shouldn't have it in the first place.
PR c++/106740
PR c++/105852
gcc/cp/ChangeLog:
* decl.c (duplicate_decls): Change non-templated friend
check to an assert.
* pt.c (tsubst_function_decl): Don't set DECL_TEMPLATE_INFO
on non-templated friends.
(tsubst_friend_function): Adjust.
gcc/testsuite/ChangeLog:
* g++.dg/template/friend78.C: New test.
^ permalink raw reply [flat|nested] 16+ messages in thread
* [Bug c++/105852] [11/12/13 Regression] ice in instantiate_decl
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
` (13 preceding siblings ...)
2023-05-09 3:47 ` cvs-commit at gcc dot gnu.org
@ 2023-05-09 3:51 ` cvs-commit at gcc dot gnu.org
14 siblings, 0 replies; 16+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-05-09 3:51 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105852
--- Comment #13 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Jason Merrill
<jason@gcc.gnu.org>:
https://gcc.gnu.org/g:8b43834d069183e14c15909e144d870c39b74028
commit r12-9519-g8b43834d069183e14c15909e144d870c39b74028
Author: Jason Merrill <jason@redhat.com>
Date: Tue Jun 7 15:52:30 2022 -0400
c++: non-templated friends [PR105852]
The previous patch for 105852 avoids copying DECL_TEMPLATE_INFO from a
non-templated friend, but it really shouldn't have it in the first place.
PR c++/106740
PR c++/105852
gcc/cp/ChangeLog:
* decl.cc (duplicate_decls): Change non-templated friend
check to an assert.
* pt.cc (tsubst_function_decl): Don't set DECL_TEMPLATE_INFO
on non-templated friends.
(tsubst_friend_function): Adjust.
gcc/testsuite/ChangeLog:
* g++.dg/template/friend78.C: New test.
^ permalink raw reply [flat|nested] 16+ messages in thread
end of thread, other threads:[~2023-05-09 3:51 UTC | newest]
Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-05 4:49 [Bug c/105852] New: ice in instantiate_decl dcb314 at hotmail dot com
2022-06-05 5:01 ` [Bug c++/105852] [13 Regression] " pinskia at gcc dot gnu.org
2022-06-05 7:02 ` dcb314 at hotmail dot com
2022-06-05 21:09 ` sam at gentoo dot org
2022-06-05 21:10 ` sam at gentoo dot org
2022-06-06 12:53 ` ppalka at gcc dot gnu.org
2022-06-06 13:03 ` [Bug c++/105852] [11/12/13 " ppalka at gcc dot gnu.org
2022-06-06 15:08 ` slyfox at gcc dot gnu.org
2022-06-06 22:39 ` jason at gcc dot gnu.org
2022-06-08 20:38 ` cvs-commit at gcc dot gnu.org
2022-06-08 20:39 ` cvs-commit at gcc dot gnu.org
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
2022-06-08 21:31 ` cvs-commit at gcc dot gnu.org
2022-06-13 12:52 ` rguenth at gcc dot gnu.org
2023-05-09 3:47 ` cvs-commit at gcc dot gnu.org
2023-05-09 3:51 ` cvs-commit at gcc dot gnu.org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).