Skip to content

Commit d183bda

Browse files
committed
Rustup to rustc 1.41.0-nightly (d1da802 2019-11-19)
1 parent aa5a95f commit d183bda

File tree

4 files changed

+28
-29
lines changed

4 files changed

+28
-29
lines changed

tests/ui/missing_const_for_fn/cant_be_const.rs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,8 @@ fn random_caller() -> u32 {
3232

3333
static Y: u32 = 0;
3434

35-
// We should not suggest to make this function `const` because const functions are not allowed to
36-
// refer to a static variable
3735
fn get_y() -> u32 {
3836
Y
39-
//~^ ERROR E0013
4037
}
4138

4239
// Don't lint entrypoint functions

tests/ui/redundant_clone.fixed

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
// run-rustfix
22
// rustfix-only-machine-applicable
3+
34
use std::ffi::OsString;
45
use std::path::Path;
56

tests/ui/redundant_clone.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
// run-rustfix
22
// rustfix-only-machine-applicable
3+
34
use std::ffi::OsString;
45
use std::path::Path;
56

tests/ui/redundant_clone.stderr

Lines changed: 26 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,156 +1,156 @@
11
error: redundant clone
2-
--> $DIR/redundant_clone.rs:7:42
2+
--> $DIR/redundant_clone.rs:8:42
33
|
44
LL | let _s = ["lorem", "ipsum"].join(" ").to_string();
55
| ^^^^^^^^^^^^ help: remove this
66
|
77
= note: `-D clippy::redundant-clone` implied by `-D warnings`
88
note: this value is dropped without further use
9-
--> $DIR/redundant_clone.rs:7:14
9+
--> $DIR/redundant_clone.rs:8:14
1010
|
1111
LL | let _s = ["lorem", "ipsum"].join(" ").to_string();
1212
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1313

1414
error: redundant clone
15-
--> $DIR/redundant_clone.rs:10:15
15+
--> $DIR/redundant_clone.rs:11:15
1616
|
1717
LL | let _s = s.clone();
1818
| ^^^^^^^^ help: remove this
1919
|
2020
note: this value is dropped without further use
21-
--> $DIR/redundant_clone.rs:10:14
21+
--> $DIR/redundant_clone.rs:11:14
2222
|
2323
LL | let _s = s.clone();
2424
| ^
2525

2626
error: redundant clone
27-
--> $DIR/redundant_clone.rs:13:15
27+
--> $DIR/redundant_clone.rs:14:15
2828
|
2929
LL | let _s = s.to_string();
3030
| ^^^^^^^^^^^^ help: remove this
3131
|
3232
note: this value is dropped without further use
33-
--> $DIR/redundant_clone.rs:13:14
33+
--> $DIR/redundant_clone.rs:14:14
3434
|
3535
LL | let _s = s.to_string();
3636
| ^
3737

3838
error: redundant clone
39-
--> $DIR/redundant_clone.rs:16:15
39+
--> $DIR/redundant_clone.rs:17:15
4040
|
4141
LL | let _s = s.to_owned();
4242
| ^^^^^^^^^^^ help: remove this
4343
|
4444
note: this value is dropped without further use
45-
--> $DIR/redundant_clone.rs:16:14
45+
--> $DIR/redundant_clone.rs:17:14
4646
|
4747
LL | let _s = s.to_owned();
4848
| ^
4949

5050
error: redundant clone
51-
--> $DIR/redundant_clone.rs:18:42
51+
--> $DIR/redundant_clone.rs:19:42
5252
|
5353
LL | let _s = Path::new("/a/b/").join("c").to_owned();
5454
| ^^^^^^^^^^^ help: remove this
5555
|
5656
note: this value is dropped without further use
57-
--> $DIR/redundant_clone.rs:18:14
57+
--> $DIR/redundant_clone.rs:19:14
5858
|
5959
LL | let _s = Path::new("/a/b/").join("c").to_owned();
6060
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
6161

6262
error: redundant clone
63-
--> $DIR/redundant_clone.rs:20:42
63+
--> $DIR/redundant_clone.rs:21:42
6464
|
6565
LL | let _s = Path::new("/a/b/").join("c").to_path_buf();
6666
| ^^^^^^^^^^^^^^ help: remove this
6767
|
6868
note: this value is dropped without further use
69-
--> $DIR/redundant_clone.rs:20:14
69+
--> $DIR/redundant_clone.rs:21:14
7070
|
7171
LL | let _s = Path::new("/a/b/").join("c").to_path_buf();
7272
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
7373

7474
error: redundant clone
75-
--> $DIR/redundant_clone.rs:22:29
75+
--> $DIR/redundant_clone.rs:23:29
7676
|
7777
LL | let _s = OsString::new().to_owned();
7878
| ^^^^^^^^^^^ help: remove this
7979
|
8080
note: this value is dropped without further use
81-
--> $DIR/redundant_clone.rs:22:14
81+
--> $DIR/redundant_clone.rs:23:14
8282
|
8383
LL | let _s = OsString::new().to_owned();
8484
| ^^^^^^^^^^^^^^^
8585

8686
error: redundant clone
87-
--> $DIR/redundant_clone.rs:24:29
87+
--> $DIR/redundant_clone.rs:25:29
8888
|
8989
LL | let _s = OsString::new().to_os_string();
9090
| ^^^^^^^^^^^^^^^ help: remove this
9191
|
9292
note: this value is dropped without further use
93-
--> $DIR/redundant_clone.rs:24:14
93+
--> $DIR/redundant_clone.rs:25:14
9494
|
9595
LL | let _s = OsString::new().to_os_string();
9696
| ^^^^^^^^^^^^^^^
9797

9898
error: redundant clone
99-
--> $DIR/redundant_clone.rs:31:19
99+
--> $DIR/redundant_clone.rs:32:19
100100
|
101101
LL | let _t = tup.0.clone();
102102
| ^^^^^^^^ help: remove this
103103
|
104104
note: this value is dropped without further use
105-
--> $DIR/redundant_clone.rs:31:14
105+
--> $DIR/redundant_clone.rs:32:14
106106
|
107107
LL | let _t = tup.0.clone();
108108
| ^^^^^
109109

110110
error: redundant clone
111-
--> $DIR/redundant_clone.rs:57:22
111+
--> $DIR/redundant_clone.rs:58:22
112112
|
113113
LL | (a.clone(), a.clone())
114114
| ^^^^^^^^ help: remove this
115115
|
116116
note: this value is dropped without further use
117-
--> $DIR/redundant_clone.rs:57:21
117+
--> $DIR/redundant_clone.rs:58:21
118118
|
119119
LL | (a.clone(), a.clone())
120120
| ^
121121

122122
error: redundant clone
123-
--> $DIR/redundant_clone.rs:113:15
123+
--> $DIR/redundant_clone.rs:114:15
124124
|
125125
LL | let _s = s.clone();
126126
| ^^^^^^^^ help: remove this
127127
|
128128
note: this value is dropped without further use
129-
--> $DIR/redundant_clone.rs:113:14
129+
--> $DIR/redundant_clone.rs:114:14
130130
|
131131
LL | let _s = s.clone();
132132
| ^
133133

134134
error: redundant clone
135-
--> $DIR/redundant_clone.rs:114:15
135+
--> $DIR/redundant_clone.rs:115:15
136136
|
137137
LL | let _t = t.clone();
138138
| ^^^^^^^^ help: remove this
139139
|
140140
note: this value is dropped without further use
141-
--> $DIR/redundant_clone.rs:114:14
141+
--> $DIR/redundant_clone.rs:115:14
142142
|
143143
LL | let _t = t.clone();
144144
| ^
145145

146146
error: redundant clone
147-
--> $DIR/redundant_clone.rs:124:19
147+
--> $DIR/redundant_clone.rs:125:19
148148
|
149149
LL | let _f = f.clone();
150150
| ^^^^^^^^ help: remove this
151151
|
152152
note: this value is dropped without further use
153-
--> $DIR/redundant_clone.rs:124:18
153+
--> $DIR/redundant_clone.rs:125:18
154154
|
155155
LL | let _f = f.clone();
156156
| ^

0 commit comments

Comments
 (0)