aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPhilip Herron <herron.philip@googlemail.com>2023-02-04 23:02:31 +0000
committerArthur Cohen <arthur.cohen@embecosm.com>2023-04-06 10:47:21 +0200
commit11150b7c05c06b5885bfc95045699baf5e5d2a34 (patch)
tree7269671ec3d69f62172dd3a6598b3a88ec62b4f7
parent9754a60623c5a3a8df0d32600345dd310812bec1 (diff)
downloadgcc-11150b7c05c06b5885bfc95045699baf5e5d2a34.zip
gcc-11150b7c05c06b5885bfc95045699baf5e5d2a34.tar.gz
gcc-11150b7c05c06b5885bfc95045699baf5e5d2a34.tar.bz2
gccrs: Remove bad error message on checking function arguments
Signed-off-by: Philip Herron <herron.philip@googlemail.com> gcc/rust/ChangeLog: * typecheck/rust-tyty-call.cc (TypeCheckCallExpr::visit): remove error message gcc/testsuite/ChangeLog: * rust/compile/func3.rs: update test case
-rw-r--r--gcc/rust/typecheck/rust-tyty-call.cc5
-rw-r--r--gcc/testsuite/rust/compile/func3.rs1
2 files changed, 0 insertions, 6 deletions
diff --git a/gcc/rust/typecheck/rust-tyty-call.cc b/gcc/rust/typecheck/rust-tyty-call.cc
index 4c6442e..67e2866 100644
--- a/gcc/rust/typecheck/rust-tyty-call.cc
+++ b/gcc/rust/typecheck/rust-tyty-call.cc
@@ -140,8 +140,6 @@ TypeCheckCallExpr::visit (FnType &type)
argument->get_locus ());
if (resolved_argument_type->get_kind () == TyTy::TypeKind::ERROR)
{
- rust_error_at (argument->get_locus (),
- "Type Resolution failure on parameter");
return;
}
}
@@ -193,8 +191,6 @@ TypeCheckCallExpr::visit (FnPtr &type)
TyWithLocation (argument_expr_tyty, arg_locus), argument->get_locus ());
if (resolved_argument_type->get_kind () == TyTy::TypeKind::ERROR)
{
- rust_error_at (argument->get_locus (),
- "Type Resolution failure on parameter");
return;
}
@@ -301,7 +297,6 @@ TypeCheckMethodCallExpr::check (FnType &type)
TyWithLocation (argument_expr_tyty, arg_locus), arg_locus);
if (resolved_argument_type->get_kind () == TyTy::TypeKind::ERROR)
{
- rust_error_at (arg_locus, "Type Resolution failure on parameter");
return new ErrorType (type.get_ref ());
}
diff --git a/gcc/testsuite/rust/compile/func3.rs b/gcc/testsuite/rust/compile/func3.rs
index 2a32947..002e5c9 100644
--- a/gcc/testsuite/rust/compile/func3.rs
+++ b/gcc/testsuite/rust/compile/func3.rs
@@ -5,5 +5,4 @@ fn test(a: i32, b: i32) -> i32 {
fn main() {
let a = test(1, true);
// { dg-error "expected .i32. got .bool." "" { target *-*-* } .-1 }
- // { dg-error "Type Resolution failure on parameter" "" { target *-*-* } .-2 }
}