From 1f44a24e725bd2fdeccfb91b0daa51788ac761f1 Mon Sep 17 00:00:00 2001 From: Maybe Waffle Date: Thu, 27 Apr 2023 17:26:59 +0000 Subject: --bless `ConstParamTy` ui tests --- tests/ui/const-generics/adt_const_params/const_param_ty_bad.rs | 2 +- .../ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.rs | 2 +- .../adt_const_params/const_param_ty_impl_bad_field.stderr | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/ui/const-generics/adt_const_params/const_param_ty_bad.rs b/tests/ui/const-generics/adt_const_params/const_param_ty_bad.rs index a9ade9d838c..0da68ae7573 100644 --- a/tests/ui/const-generics/adt_const_params/const_param_ty_bad.rs +++ b/tests/ui/const-generics/adt_const_params/const_param_ty_bad.rs @@ -5,7 +5,7 @@ fn check(_: impl std::marker::ConstParamTy) {} fn main() { check(main); //~ error: `fn() {main}` can't be used as a const parameter type - check(|| {}); //~ error: `[closure@fake-test-src-base/const-generics/adt_const_params/const_param_ty_bad.rs:8:11: 8:13]` can't be used as a const parameter type + check(|| {}); //~ error: `[closure@$DIR/const_param_ty_bad.rs:8:11: 8:13]` can't be used as a const parameter type check(main as fn()); //~ error: `fn()` can't be used as a const parameter type check(&mut ()); //~ error: `&mut ()` can't be used as a const parameter type check(&mut () as *mut ()); //~ error: `*mut ()` can't be used as a const parameter type diff --git a/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.rs b/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.rs index 3d2d99b9d38..07fd243737e 100644 --- a/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.rs +++ b/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.rs @@ -8,6 +8,6 @@ struct NotParam; struct CantParam(NotParam); impl std::marker::ConstParamTy for CantParam {} -//~^ error: the trait `ConstParamTy` may not be implemented for this type +//~^ error: the trait `ConstParamTy` cannot be implemented for this type fn main() {} diff --git a/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.stderr b/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.stderr index 5cd5cae6d79..c8e065848b1 100644 --- a/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.stderr +++ b/tests/ui/const-generics/adt_const_params/const_param_ty_impl_bad_field.stderr @@ -1,4 +1,4 @@ -error[E0204]: the trait `ConstParamTy` may not be implemented for this type +error[E0204]: the trait `ConstParamTy` cannot be implemented for this type --> $DIR/const_param_ty_impl_bad_field.rs:10:36 | LL | struct CantParam(NotParam); -- cgit 1.4.1-3-g733a5