aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Herron <herron.philip@googlemail.com>2023-02-27 16:38:41 +0000
committerPhilip Herron <philip.herron@embecosm.com>2023-02-28 20:38:35 +0000
commitea139aa3818bf07f3ad565dd00889f4caa171c14 (patch)
treee7beb790a56e219390e43a0510bc602235fc4706
parente164f32df23b309963bf17bf725cd8fcae58d2d5 (diff)
downloadgcc-ea139aa3818bf07f3ad565dd00889f4caa171c14.zip
gcc-ea139aa3818bf07f3ad565dd00889f4caa171c14.tar.gz
gcc-ea139aa3818bf07f3ad565dd00889f4caa171c14.tar.bz2
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
-rw-r--r--gcc/rust/typecheck/rust-unify.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/rust/typecheck/rust-unify.cc b/gcc/rust/typecheck/rust-unify.cc
index 70210aa..e76b362 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;