public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
@ 2020-08-22 12:47 src at andyf dot de
2020-09-22 19:34 ` [Bug c++/96745] " ppalka at gcc dot gnu.org
` (8 more replies)
0 siblings, 9 replies; 10+ messages in thread
From: src at andyf dot de @ 2020-08-22 12:47 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Bug ID: 96745
Summary: [concepts] internal compiler error: in
type_memfn_rqual, at cp/typeck.c:10389
Product: gcc
Version: 10.2.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: src at andyf dot de
Target Milestone: ---
Hello,
the following code gives an internal compiler error.
template<typename T>
struct Test {
~Test() requires true {}
~Test() requires true && true {}
};
Test<int> t;
Error:
<source>: In instantiation of 'struct Test<int>':
<source>:7:11: required from here
<source>:2:8: internal compiler error: in type_memfn_rqual, at
cp/typeck.c:10389
2 | struct Test {
| ^~~~
Please submit a full bug report,
with preprocessed source if appropriate.
See <https://gcc.gnu.org/bugs/> for instructions.
Compiler returned: 1
The code is ill-formed, the compiler cannot identify which of the two
destructors is the most constrained. However, I think a more helpful error
message would assist me in a large code-base much more.
Live: https://godbolt.org/z/6dP8PG
Andreas
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
@ 2020-09-22 19:34 ` ppalka at gcc dot gnu.org
2021-01-17 16:52 ` ppalka at gcc dot gnu.org
` (7 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2020-09-22 19:34 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |NEW
Last reconfirmed| |2020-09-22
Ever confirmed|0 |1
Known to fail| |10.2.0, 11.0
CC| |ppalka at gcc dot gnu.org
--- Comment #1 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Confirmed.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
2020-09-22 19:34 ` [Bug c++/96745] " ppalka at gcc dot gnu.org
@ 2021-01-17 16:52 ` ppalka at gcc dot gnu.org
2021-01-17 16:57 ` ppalka at gcc dot gnu.org
` (6 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2021-01-17 16:52 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |ryan_greenblatt at brown dot edu
--- Comment #2 from Patrick Palka <ppalka at gcc dot gnu.org> ---
*** Bug 98711 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
2020-09-22 19:34 ` [Bug c++/96745] " ppalka at gcc dot gnu.org
2021-01-17 16:52 ` ppalka at gcc dot gnu.org
@ 2021-01-17 16:57 ` ppalka at gcc dot gnu.org
2021-05-05 16:30 ` ppalka at gcc dot gnu.org
` (5 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2021-01-17 16:57 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Assignee|unassigned at gcc dot gnu.org |ppalka at gcc dot gnu.org
Status|NEW |ASSIGNED
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (2 preceding siblings ...)
2021-01-17 16:57 ` ppalka at gcc dot gnu.org
@ 2021-05-05 16:30 ` ppalka at gcc dot gnu.org
2021-09-07 20:43 ` pinskia at gcc dot gnu.org
` (4 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2021-05-05 16:30 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |gcc_report_187375@mailfence
| |.com
--- Comment #3 from Patrick Palka <ppalka at gcc dot gnu.org> ---
*** Bug 100421 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (3 preceding siblings ...)
2021-05-05 16:30 ` ppalka at gcc dot gnu.org
@ 2021-09-07 20:43 ` pinskia at gcc dot gnu.org
2023-01-30 20:36 ` ppalka at gcc dot gnu.org
` (3 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: pinskia at gcc dot gnu.org @ 2021-09-07 20:43 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Andrew Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |sin-ack at protonmail dot com
--- Comment #4 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
*** Bug 102234 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (4 preceding siblings ...)
2021-09-07 20:43 ` pinskia at gcc dot gnu.org
@ 2023-01-30 20:36 ` ppalka at gcc dot gnu.org
2023-02-03 14:15 ` cvs-commit at gcc dot gnu.org
` (2 subsequent siblings)
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-01-30 20:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |etienne.doms at gmail dot com
--- Comment #5 from Patrick Palka <ppalka at gcc dot gnu.org> ---
*** Bug 108479 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (5 preceding siblings ...)
2023-01-30 20:36 ` ppalka at gcc dot gnu.org
@ 2023-02-03 14:15 ` cvs-commit at gcc dot gnu.org
2023-02-03 14:21 ` ppalka at gcc dot gnu.org
2023-02-03 14:23 ` ppalka at gcc dot gnu.org
8 siblings, 0 replies; 10+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-02-03 14:15 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
--- Comment #6 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Patrick Palka <ppalka@gcc.gnu.org>:
https://gcc.gnu.org/g:ed2b519e02eac99fadfa51adc7b11f8854c24575
commit r13-5683-ged2b519e02eac99fadfa51adc7b11f8854c24575
Author: Patrick Palka <ppalka@redhat.com>
Date: Fri Feb 3 09:15:29 2023 -0500
c++: ICE on unviable/ambiguous constrained dtors [PR96745]
Here we're crashing from check_bases_and_members due to
CLASSTYPE_DESTRUCTOR being an OVERLOAD which, due to the pruning
performed by add_method, should only happen if there is no viable
destructor or the destructor is ambiguous because of unsatisfied
or ambiguous constraints.
This patch fixes this by making check_bases_and_members naturally handle
CLASSTYPE_DESTRUCTOR being an OVERLOAD. It's then convenient to prune
the OVERLOAD after effectively diagnosing the overload resolution
failure in check_methods.
PR c++/96745
gcc/cp/ChangeLog:
* class.cc (check_methods): Diagnose an unviable OVERLOAD
set for CLASSTYPE_DESTRUCTOR differently from an ambiguous one.
Then prune the OVERLOAD to a single function.
(check_bases_and_members): Handle CLASSTYPE_DESTRUCTOR being
an OVERLOAD when calling deduce_noexcept_on_destructor.
Document why it has to be called before check_methods.
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/concepts-dtor1.C: New test.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (6 preceding siblings ...)
2023-02-03 14:15 ` cvs-commit at gcc dot gnu.org
@ 2023-02-03 14:21 ` ppalka at gcc dot gnu.org
2023-02-03 14:23 ` ppalka at gcc dot gnu.org
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-02-03 14:21 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Keywords| |ice-on-invalid-code
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
Target Milestone|--- |13.0
--- Comment #7 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Fixed for GCC 13, thanks for the bug report. This doesn't seem worth
backporting since the ICE only happens on invalid code.
^ permalink raw reply [flat|nested] 10+ messages in thread
* [Bug c++/96745] [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
` (7 preceding siblings ...)
2023-02-03 14:21 ` ppalka at gcc dot gnu.org
@ 2023-02-03 14:23 ` ppalka at gcc dot gnu.org
8 siblings, 0 replies; 10+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-02-03 14:23 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96745
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
CC| |asolokha at gmx dot com
--- Comment #8 from Patrick Palka <ppalka at gcc dot gnu.org> ---
*** Bug 107150 has been marked as a duplicate of this bug. ***
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2023-02-03 14:23 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-22 12:47 [Bug c++/96745] New: [concepts] internal compiler error: in type_memfn_rqual, at cp/typeck.c:10389 src at andyf dot de
2020-09-22 19:34 ` [Bug c++/96745] " ppalka at gcc dot gnu.org
2021-01-17 16:52 ` ppalka at gcc dot gnu.org
2021-01-17 16:57 ` ppalka at gcc dot gnu.org
2021-05-05 16:30 ` ppalka at gcc dot gnu.org
2021-09-07 20:43 ` pinskia at gcc dot gnu.org
2023-01-30 20:36 ` ppalka at gcc dot gnu.org
2023-02-03 14:15 ` cvs-commit at gcc dot gnu.org
2023-02-03 14:21 ` ppalka at gcc dot gnu.org
2023-02-03 14:23 ` ppalka 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).