* [Bug c++/107179] [11/12/13 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
@ 2022-10-07 13:19 ` ppalka at gcc dot gnu.org
2022-10-18 8:34 ` rguenth at gcc dot gnu.org
` (4 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: ppalka at gcc dot gnu.org @ 2022-10-07 13:19 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|UNCONFIRMED |ASSIGNED
Assignee|unassigned at gcc dot gnu.org |ppalka at gcc dot gnu.org
Last reconfirmed| |2022-10-07
CC| |ppalka at gcc dot gnu.org
Summary|requires-expression gives |[11/12/13 Regression]
|hard error for inaccessible |requires-expression gives
|constructor |hard error for inaccessible
| |constructor
Known to fail| |11.3.0, 12.2.0
Ever confirmed|0 |1
Target Milestone|--- |11.4
Known to work| |10.3.0
--- Comment #1 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Started with r11-6815-g79e1251b642db0
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/107179] [11/12/13 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
2022-10-07 13:19 ` [Bug c++/107179] [11/12/13 Regression] " ppalka at gcc dot gnu.org
@ 2022-10-18 8:34 ` rguenth at gcc dot gnu.org
2022-11-03 19:36 ` cvs-commit at gcc dot gnu.org
` (3 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: rguenth at gcc dot gnu.org @ 2022-10-18 8:34 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
Richard Biener <rguenth at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Priority|P3 |P2
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/107179] [11/12/13 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
2022-10-07 13:19 ` [Bug c++/107179] [11/12/13 Regression] " ppalka at gcc dot gnu.org
2022-10-18 8:34 ` rguenth at gcc dot gnu.org
@ 2022-11-03 19:36 ` cvs-commit at gcc dot gnu.org
2023-03-07 2:18 ` [Bug c++/107179] [11/12 " cvs-commit at gcc dot gnu.org
` (2 subsequent siblings)
5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2022-11-03 19:36 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
--- Comment #2 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:40c34beef620ed13c4113c893ed4335ccc1b8f92
commit r13-3641-g40c34beef620ed13c4113c893ed4335ccc1b8f92
Author: Patrick Palka <ppalka@redhat.com>
Date: Thu Nov 3 15:35:18 2022 -0400
c++: requires-expr and access checking [PR107179]
Like during satisfaction, we also need to avoid deferring access checks
during substitution of a requires-expr because the outcome of an access
check can determine the value of the requires-expr. Otherwise (in
deferred access checking contexts such as within a base-clause), the
requires-expr may evaluate to the wrong result, and along the way a
failed access check may leak out from it into a non-SFINAE context and
cause a hard error (as in the below testcase).
PR c++/107179
gcc/cp/ChangeLog:
* constraint.cc (tsubst_requires_expr): Make sure we're not
deferring access checks.
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/concepts-requires31.C: New test.
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/107179] [11/12 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
` (2 preceding siblings ...)
2022-11-03 19:36 ` cvs-commit at gcc dot gnu.org
@ 2023-03-07 2:18 ` cvs-commit at gcc dot gnu.org
2023-05-22 3:12 ` [Bug c++/107179] [11 " cvs-commit at gcc dot gnu.org
2023-05-22 3:14 ` ppalka at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-03-07 2:18 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Patrick Palka
<ppalka@gcc.gnu.org>:
https://gcc.gnu.org/g:668098c2e55c33f97e331c3160174bf12c3d88f7
commit r12-9227-g668098c2e55c33f97e331c3160174bf12c3d88f7
Author: Patrick Palka <ppalka@redhat.com>
Date: Thu Nov 3 15:35:18 2022 -0400
c++: requires-expr and access checking [PR107179]
Like during satisfaction, we also need to avoid deferring access checks
during substitution of a requires-expr because the outcome of an access
check can determine the value of the requires-expr. Otherwise (in
deferred access checking contexts such as within a base-clause), the
requires-expr may evaluate to the wrong result, and along the way a
failed access check may leak out from it into a non-SFINAE context and
cause a hard error (as in the below testcase).
PR c++/107179
gcc/cp/ChangeLog:
* constraint.cc (tsubst_requires_expr): Make sure we're not
deferring access checks.
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/concepts-requires31.C: New test.
(cherry picked from commit 40c34beef620ed13c4113c893ed4335ccc1b8f92)
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/107179] [11 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
` (3 preceding siblings ...)
2023-03-07 2:18 ` [Bug c++/107179] [11/12 " cvs-commit at gcc dot gnu.org
@ 2023-05-22 3:12 ` cvs-commit at gcc dot gnu.org
2023-05-22 3:14 ` ppalka at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: cvs-commit at gcc dot gnu.org @ 2023-05-22 3:12 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-11 branch has been updated by Patrick Palka
<ppalka@gcc.gnu.org>:
https://gcc.gnu.org/g:c0658801e10d2e7e8b137e555d4c2817bf090ea9
commit r11-10802-gc0658801e10d2e7e8b137e555d4c2817bf090ea9
Author: Patrick Palka <ppalka@redhat.com>
Date: Thu Nov 3 15:35:18 2022 -0400
c++: requires-expr and access checking [PR107179]
Like during satisfaction, we also need to avoid deferring access checks
during substitution of a requires-expr because the outcome of an access
check can determine the value of the requires-expr. Otherwise (in
deferred access checking contexts such as within a base-clause), the
requires-expr may evaluate to the wrong result, and along the way a
failed access check may leak out from it into a non-SFINAE context and
cause a hard error (as in the below testcase).
PR c++/107179
gcc/cp/ChangeLog:
* constraint.cc (tsubst_requires_expr): Make sure we're not
deferring access checks.
gcc/testsuite/ChangeLog:
* g++.dg/cpp2a/concepts-requires31.C: New test.
(cherry picked from commit 40c34beef620ed13c4113c893ed4335ccc1b8f92)
^ permalink raw reply [flat|nested] 7+ messages in thread
* [Bug c++/107179] [11 Regression] requires-expression gives hard error for inaccessible constructor
2022-10-07 11:53 [Bug c++/107179] New: requires-expression gives hard error for inaccessible constructor redi at gcc dot gnu.org
` (4 preceding siblings ...)
2023-05-22 3:12 ` [Bug c++/107179] [11 " cvs-commit at gcc dot gnu.org
@ 2023-05-22 3:14 ` ppalka at gcc dot gnu.org
5 siblings, 0 replies; 7+ messages in thread
From: ppalka at gcc dot gnu.org @ 2023-05-22 3:14 UTC (permalink / raw)
To: gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=107179
Patrick Palka <ppalka at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution|--- |FIXED
--- Comment #5 from Patrick Palka <ppalka at gcc dot gnu.org> ---
Fixed for GCC 11.4+
^ permalink raw reply [flat|nested] 7+ messages in thread