diff --git a/tests/ui/auto-traits/issue-83857-ub.rs b/tests/ui/auto-traits/issue-83857-ub.rs index 0a8865295c6..626e60c37f6 100644 --- a/tests/ui/auto-traits/issue-83857-ub.rs +++ b/tests/ui/auto-traits/issue-83857-ub.rs @@ -1,4 +1,6 @@ #![allow(suspicious_auto_trait_impls)] +// Tests that we don't incorrectly allow overlap between a builtin auto trait +// impl and a user written one. See #83857 for more details struct Always(T, U); unsafe impl Send for Always {} diff --git a/tests/ui/auto-traits/issue-83857-ub.stderr b/tests/ui/auto-traits/issue-83857-ub.stderr index d2aef17e7f8..23a2f62d905 100644 --- a/tests/ui/auto-traits/issue-83857-ub.stderr +++ b/tests/ui/auto-traits/issue-83857-ub.stderr @@ -1,12 +1,12 @@ error[E0277]: `Foo` cannot be sent between threads safely - --> $DIR/issue-83857-ub.rs:20:38 + --> $DIR/issue-83857-ub.rs:22:38 | LL | fn generic(v: Foo, f: fn( as WithAssoc>::Output) -> i32) { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ `Foo` cannot be sent between threads safely | = help: the trait `Send` is not implemented for `Foo` note: required for `Foo` to implement `WithAssoc` - --> $DIR/issue-83857-ub.rs:13:15 + --> $DIR/issue-83857-ub.rs:15:15 | LL | impl WithAssoc for T { | ---- ^^^^^^^^^ ^ diff --git a/tests/ui/impl-trait/auto-trait-leak b/tests/ui/impl-trait/auto-trait-leak deleted file mode 100644 index e69de29bb2d..00000000000