forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Auto merge of rust-lang#90883 - matthiaskrgr:rollup-iu9k5pe, r=matthi…
…askrgr Rollup of 3 pull requests Successful merges: - rust-lang#90771 (Fix trait object error code) - rust-lang#90840 (relate lifetime in `TypeOutlives` bounds on drop impls) - rust-lang#90853 (rustdoc: Use an empty Vec instead of Option<Vec>) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
- Loading branch information
Showing
7 changed files
with
46 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
struct Wrapper<'a, T>(&'a T) | ||
where | ||
T: 'a; | ||
|
||
impl<'a, T> Drop for Wrapper<'a, T> | ||
where | ||
T: 'static, | ||
//~^ error: `Drop` impl requires `T: 'static` but the struct it is implemented for does not | ||
{ | ||
fn drop(&mut self) {} | ||
} | ||
|
||
fn main() {} |
17 changes: 17 additions & 0 deletions
17
src/test/ui/dropck/relate_lt_in_type_outlives_bound.stderr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
error[E0367]: `Drop` impl requires `T: 'static` but the struct it is implemented for does not | ||
--> $DIR/relate_lt_in_type_outlives_bound.rs:7:8 | ||
| | ||
LL | T: 'static, | ||
| ^^^^^^^ | ||
| | ||
note: the implementor must specify the same requirement | ||
--> $DIR/relate_lt_in_type_outlives_bound.rs:1:1 | ||
| | ||
LL | / struct Wrapper<'a, T>(&'a T) | ||
LL | | where | ||
LL | | T: 'a; | ||
| |__________^ | ||
|
||
error: aborting due to previous error | ||
|
||
For more information about this error, try `rustc --explain E0367`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
error[E0783]: trait objects without an explicit `dyn` are deprecated | ||
error[E0782]: trait objects without an explicit `dyn` are deprecated | ||
--> $DIR/dyn-trait-sugg-2021.rs:10:5 | ||
| | ||
LL | Foo::hi(123); | ||
| ^^^ help: use `dyn`: `<dyn Foo>` | ||
|
||
error: aborting due to previous error | ||
|
||
For more information about this error, try `rustc --explain E0783`. | ||
For more information about this error, try `rustc --explain E0782`. |