[gcc r14-7305] gccrs: Only emit errors during type-bounds checking when required
Arthur Cohen
cohenarthur@gcc.gnu.org
Tue Jan 16 17:21:04 GMT 2024
https://gcc.gnu.org/g:a313761b2f506093b8ed8134338b935f968ca380
commit r14-7305-ga313761b2f506093b8ed8134338b935f968ca380
Author: Philip Herron <herron.philip@googlemail.com>
Date: Mon Feb 27 16:38:41 2023 +0000
gccrs: Only emit errors during type-bounds checking when required
Signed-off-by: Philip Herron <herron.philip@googlemail.com>
gcc/rust/ChangeLog:
* typecheck/rust-unify.cc (UnifyRules::go): respect the emit_errors flag
Diff:
---
gcc/rust/typecheck/rust-unify.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gcc/rust/typecheck/rust-unify.cc b/gcc/rust/typecheck/rust-unify.cc
index bdee48bdc42..dcd1783c29a 100644
--- a/gcc/rust/typecheck/rust-unify.cc
+++ b/gcc/rust/typecheck/rust-unify.cc
@@ -141,7 +141,7 @@ UnifyRules::go ()
// check bounds
if (ltype->num_specified_bounds () > 0)
{
- if (!ltype->bounds_compatible (*rtype, locus, true))
+ if (!ltype->bounds_compatible (*rtype, locus, emit_error))
{
// already emitted an error
emit_error = false;
More information about the Gcc-cvs
mailing list