From 64d98f8ee037282c35007b64c2649055c56af1db Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 17 Apr 2024 14:19:03 +0200 Subject: Merging upstream version 1.68.2+dfsg1. Signed-off-by: Daniel Baumann --- .../generic_underconstrained2.stderr | 35 ++++++++++++++++++++++ 1 file changed, 35 insertions(+) create mode 100644 tests/ui/type-alias-impl-trait/generic_underconstrained2.stderr (limited to 'tests/ui/type-alias-impl-trait/generic_underconstrained2.stderr') diff --git a/tests/ui/type-alias-impl-trait/generic_underconstrained2.stderr b/tests/ui/type-alias-impl-trait/generic_underconstrained2.stderr new file mode 100644 index 000000000..d77d978aa --- /dev/null +++ b/tests/ui/type-alias-impl-trait/generic_underconstrained2.stderr @@ -0,0 +1,35 @@ +error[E0277]: `U` doesn't implement `Debug` + --> $DIR/generic_underconstrained2.rs:8:33 + | +LL | fn underconstrained(_: U) -> Underconstrained { + | ^^^^^^^^^^^^^^^^^^^ `U` cannot be formatted using `{:?}` because it doesn't implement `Debug` + | +note: required by a bound in `Underconstrained` + --> $DIR/generic_underconstrained2.rs:5:26 + | +LL | type Underconstrained = impl Send; + | ^^^^^^^^^^^^^^^ required by this bound in `Underconstrained` +help: consider restricting type parameter `U` + | +LL | fn underconstrained(_: U) -> Underconstrained { + | +++++++++++++++++ + +error[E0277]: `V` doesn't implement `Debug` + --> $DIR/generic_underconstrained2.rs:16:43 + | +LL | fn underconstrained2(_: U, _: V) -> Underconstrained2 { + | ^^^^^^^^^^^^^^^^^^^^ `V` cannot be formatted using `{:?}` because it doesn't implement `Debug` + | +note: required by a bound in `Underconstrained2` + --> $DIR/generic_underconstrained2.rs:13:27 + | +LL | type Underconstrained2 = impl Send; + | ^^^^^^^^^^^^^^^ required by this bound in `Underconstrained2` +help: consider restricting type parameter `V` + | +LL | fn underconstrained2(_: U, _: V) -> Underconstrained2 { + | +++++++++++++++++ + +error: aborting due to 2 previous errors + +For more information about this error, try `rustc --explain E0277`. -- cgit v1.2.3