mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-03-22 00:01:10 +08:00
Suppress diagnostics substituting into a requires-expression (PR c++/92403).
gcc/cp/ * pt.c (tsubst_copy_and_build): Perform the first substitution without diagnostics and a second only if tsubst_requries_expr returns an error. From-SVN: r278449
This commit is contained in:
parent
8b24d594fe
commit
7aabd67f18
@ -1,3 +1,10 @@
|
||||
2019-11-19 Andrew Sutton <asutton@lock3software.com>
|
||||
|
||||
PR c++/92403
|
||||
Suppress diagnostics substituting into a requires-expression.
|
||||
* pt.c (tsubst_copy_and_build): Perform the first substitution without
|
||||
diagnostics and a second only if tsubst_requries_expr returns an error.
|
||||
|
||||
2019-11-19 Jakub Jelinek <jakub@redhat.com>
|
||||
|
||||
PR c++/92504
|
||||
|
@ -20139,7 +20139,12 @@ tsubst_copy_and_build (tree t,
|
||||
}
|
||||
|
||||
case REQUIRES_EXPR:
|
||||
RETURN (tsubst_requires_expr (t, args, complain, in_decl));
|
||||
{
|
||||
tree r = tsubst_requires_expr (t, args, tf_none, in_decl);
|
||||
if (r == error_mark_node && (complain & tf_error))
|
||||
tsubst_requires_expr (t, args, complain, in_decl);
|
||||
RETURN (r);
|
||||
}
|
||||
|
||||
case RANGE_EXPR:
|
||||
/* No need to substitute further, a RANGE_EXPR will always be built
|
||||
|
Loading…
x
Reference in New Issue
Block a user