diff --git a/tests/ui/pin_project/safe_packed_borrows.stderr b/tests/ui/pin_project/safe_packed_borrows.stderr index cc4b9078..7b4cc08e 100644 --- a/tests/ui/pin_project/safe_packed_borrows.stderr +++ b/tests/ui/pin_project/safe_packed_borrows.stderr @@ -4,7 +4,7 @@ error: borrow of packed field is unsafe and requires unsafe function or block (e 17 | &a.field; //~ ERROR borrow of packed field is unsafe and requires unsafe function or block | ^^^^^^^^ | -note: lint level defined here +note: the lint level is defined here --> $DIR/safe_packed_borrows.rs:1:9 | 1 | #![deny(safe_packed_borrows)] diff --git a/tests/ui/unstable-features/run-pass/overlapping_marker_traits.rs b/tests/ui/unstable-features/overlapping_marker_traits.rs similarity index 61% rename from tests/ui/unstable-features/run-pass/overlapping_marker_traits.rs rename to tests/ui/unstable-features/overlapping_marker_traits.rs index b030f743..28b23fe3 100644 --- a/tests/ui/unstable-features/run-pass/overlapping_marker_traits.rs +++ b/tests/ui/unstable-features/overlapping_marker_traits.rs @@ -1,11 +1,15 @@ // NB: If you change this test, change 'overlapping_marker_traits-feature-gate.rs' at the same time. +// This feature could break the guarantee for Unpin provided by pin-project, +// but was removed in https://github.com/rust-lang/rust/pull/68544 (nightly-2020-02-06). +// Refs: +// * https://github.com/rust-lang/rust/issues/29864#issuecomment-515780867. +// * https://github.com/taiki-e/pin-project/issues/105 + // overlapping_marker_traits // Tracking issue: https://github.com/rust-lang/rust/issues/29864 #![feature(overlapping_marker_traits)] -// See https://github.com/rust-lang/rust/issues/29864#issuecomment-515780867. - use pin_project::pin_project; use std::marker::PhantomPinned; diff --git a/tests/ui/unstable-features/overlapping_marker_traits.stderr b/tests/ui/unstable-features/overlapping_marker_traits.stderr new file mode 100644 index 00000000..35972eeb --- /dev/null +++ b/tests/ui/unstable-features/overlapping_marker_traits.stderr @@ -0,0 +1,16 @@ +error[E0557]: feature has been removed + --> $DIR/overlapping_marker_traits.rs:11:12 + | +11 | #![feature(overlapping_marker_traits)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^ feature has been removed + | + = note: removed in favor of `#![feature(marker_trait_attr)]` + +error[E0119]: conflicting implementations of trait `std::marker::Unpin` for type `Foo<_>`: + --> $DIR/overlapping_marker_traits.rs:16:1 + | +16 | #[pin_project] + | ^^^^^^^^^^^^^^ conflicting implementation for `Foo<_>` +... +23 | impl<T> Unpin for Foo<T> {} + | ------------------------ first implementation here diff --git a/tests/ui/unstable-features/trivial_bounds-bug.stderr b/tests/ui/unstable-features/trivial_bounds-bug.stderr index 5ffab340..417106fb 100644 --- a/tests/ui/unstable-features/trivial_bounds-bug.stderr +++ b/tests/ui/unstable-features/trivial_bounds-bug.stderr @@ -1,8 +1,8 @@ error[E0277]: the trait bound `std::marker::PhantomPinned: std::marker::Unpin` is not satisfied - --> $DIR/trivial_bounds-bug.rs:13:5 + --> $DIR/trivial_bounds-bug.rs:13:43 | 13 | impl Unpin for A where PhantomPinned: Unpin {} //~ ERROR E0277 - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ the trait `std::marker::Unpin` is not implemented for `std::marker::PhantomPinned` + | ^^^^^ the trait `std::marker::Unpin` is not implemented for `std::marker::PhantomPinned` | = help: the following implementations were found: <std::marker::PhantomPinned as std::marker::Unpin> diff --git a/tests/ui/unstable-features/trivial_bounds-feature-gate.stderr b/tests/ui/unstable-features/trivial_bounds-feature-gate.stderr index 418231c3..24a81f4f 100644 --- a/tests/ui/unstable-features/trivial_bounds-feature-gate.stderr +++ b/tests/ui/unstable-features/trivial_bounds-feature-gate.stderr @@ -9,6 +9,16 @@ error[E0277]: the trait bound `std::marker::PhantomPinned: std::marker::Unpin` i = help: see issue #48214 = help: add `#![feature(trivial_bounds)]` to the crate attributes to enable +error[E0277]: the trait bound `std::marker::PhantomPinned: std::marker::Unpin` is not satisfied + --> $DIR/trivial_bounds-feature-gate.rs:8:43 + | +8 | impl Unpin for A where PhantomPinned: Unpin {} //~ ERROR E0277 + | ^^^^^ the trait `std::marker::Unpin` is not implemented for `std::marker::PhantomPinned` + | + = help: the following implementations were found: + <std::marker::PhantomPinned as std::marker::Unpin> + = note: required by `std::marker::Unpin` + error[E0277]: the trait bound `std::marker::PhantomPinned: std::marker::Unpin` is not satisfied --> $DIR/trivial_bounds-feature-gate.rs:16:5 | diff --git a/tests/ui/unstable-features/trivial_bounds.stderr b/tests/ui/unstable-features/trivial_bounds.stderr index 4b85b67a..03d01614 100644 --- a/tests/ui/unstable-features/trivial_bounds.stderr +++ b/tests/ui/unstable-features/trivial_bounds.stderr @@ -4,7 +4,7 @@ error: Trait bound inner::Inner: std::marker::Unpin does not depend on any type 15 | impl Unpin for A where Inner: Unpin {} //~ ERROR std::marker::Unpin does not depend on any type or lifetime parameters | ^^^^^ | -note: lint level defined here +note: the lint level is defined here --> $DIR/trivial_bounds.rs:6:9 | 6 | #![deny(trivial_bounds)]