Skip to content

Commit 32dc1ca

Browse files
committed
Bless rest tests
1 parent 05b323b commit 32dc1ca

48 files changed

Lines changed: 394 additions & 794 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

tests/ui/async-await/async-drop/ex-ice-132103.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
//@ edition: 2018
66
#![feature(async_drop)]
77
#![allow(incomplete_features)]
8+
#![allow(redundant_self)]
89

910
use core::future::{async_drop_in_place, Future};
1011
use core::mem::{self};

tests/ui/delegation/target-expr-pass.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
#![feature(fn_delegation)]
44
#![allow(incomplete_features)]
5+
#![allow(redundant_self)]
56

67
mod to_reuse {
78
pub fn foo(x: i32) -> i32 { x }

tests/ui/delegation/target-expr-pass.stderr

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,19 @@
11
warning: trait `Trait` is never used
2-
--> $DIR/target-expr-pass.rs:17:7
2+
--> $DIR/target-expr-pass.rs:18:7
33
|
44
LL | trait Trait {
55
| ^^^^^
66
|
77
= note: `#[warn(dead_code)]` (part of `#[warn(unused)]`) on by default
88

99
warning: struct `F` is never constructed
10-
--> $DIR/target-expr-pass.rs:21:8
10+
--> $DIR/target-expr-pass.rs:22:8
1111
|
1212
LL | struct F;
1313
| ^
1414

1515
warning: struct `S` is never constructed
16-
--> $DIR/target-expr-pass.rs:24:8
16+
--> $DIR/target-expr-pass.rs:25:8
1717
|
1818
LL | struct S(F);
1919
| ^

tests/ui/error-codes/E0429.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1-
use std::fmt::self; //~ ERROR E0429
1+
#![deny(redundant_self)]
2+
3+
use std::fmt::self; //~ ERROR unnecessary `self`
24

35
fn main () {
46
}

tests/ui/error-codes/E0429.stderr

Lines changed: 9 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,16 @@
1-
error[E0429]: `self` imports are only allowed within a { } list
2-
--> $DIR/E0429.rs:1:13
1+
error: unnecessary `self`
2+
--> $DIR/E0429.rs:3:15
33
|
44
LL | use std::fmt::self;
5-
| ^^^^^^
5+
| --^^^^
6+
| |
7+
| help: consider removing this
68
|
7-
help: consider importing the module directly
9+
note: the lint level is defined here
10+
--> $DIR/E0429.rs:1:9
811
|
9-
LL - use std::fmt::self;
10-
LL + use std::fmt;
11-
|
12-
help: alternatively, use the multi-path `use` syntax to import `self`
13-
|
14-
LL | use std::fmt::{self};
15-
| + +
12+
LL | #![deny(redundant_self)]
13+
| ^^^^^^^^^^^^^^
1614

1715
error: aborting due to 1 previous error
1816

19-
For more information about this error, try `rustc --explain E0429`.

tests/ui/imports/cycle-import-in-std-1.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
// https://github.com/rust-lang/rust/issues/124490
44

5+
#![allow(redundant_self)]
6+
57
use ops::{self as std};
68
//~^ ERROR: unresolved import `ops`
79
use std::collections::{self as ops};

tests/ui/imports/cycle-import-in-std-1.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0432]: unresolved import `ops`
2-
--> $DIR/cycle-import-in-std-1.rs:5:11
2+
--> $DIR/cycle-import-in-std-1.rs:7:11
33
|
44
LL | use ops::{self as std};
55
| ^^^^^^^^^^^ no external crate `ops`

tests/ui/imports/cycle-import-in-std-2.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
// https://github.com/rust-lang/rust/issues/125013
44

5+
#![allow(redundant_self)]
6+
57
use ops::{self as std};
68
//~^ ERROR: unresolved import `ops`
79
use std::ops::Deref::{self as ops};

tests/ui/imports/cycle-import-in-std-2.stderr

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
error[E0432]: unresolved import `ops`
2-
--> $DIR/cycle-import-in-std-2.rs:5:11
2+
--> $DIR/cycle-import-in-std-2.rs:7:11
33
|
44
LL | use ops::{self as std};
55
| ^^^^^^^^^^^ no external crate `ops`

tests/ui/imports/import-rename.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
//@ run-pass
22
#![allow(unused_variables)]
3+
#![allow(redundant_self)]
4+
35
use foo::{x, y as fooy};
46
use Maybe::{Yes as MaybeYes};
57

0 commit comments

Comments
 (0)