]> git.proxmox.com Git - rustc.git/blame - src/tools/clippy/tests/ui/redundant_clone.stderr
Update upstream source from tag 'upstream/1.52.1+dfsg1'
[rustc.git] / src / tools / clippy / tests / ui / redundant_clone.stderr
CommitLineData
f20569fa
XL
1error: redundant clone
2 --> $DIR/redundant_clone.rs:9:42
3 |
4LL | let _s = ["lorem", "ipsum"].join(" ").to_string();
5 | ^^^^^^^^^^^^ help: remove this
6 |
7 = note: `-D clippy::redundant-clone` implied by `-D warnings`
8note: this value is dropped without further use
9 --> $DIR/redundant_clone.rs:9:14
10 |
11LL | let _s = ["lorem", "ipsum"].join(" ").to_string();
12 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
13
14error: redundant clone
15 --> $DIR/redundant_clone.rs:12:15
16 |
17LL | let _s = s.clone();
18 | ^^^^^^^^ help: remove this
19 |
20note: this value is dropped without further use
21 --> $DIR/redundant_clone.rs:12:14
22 |
23LL | let _s = s.clone();
24 | ^
25
26error: redundant clone
27 --> $DIR/redundant_clone.rs:15:15
28 |
29LL | let _s = s.to_string();
30 | ^^^^^^^^^^^^ help: remove this
31 |
32note: this value is dropped without further use
33 --> $DIR/redundant_clone.rs:15:14
34 |
35LL | let _s = s.to_string();
36 | ^
37
38error: redundant clone
39 --> $DIR/redundant_clone.rs:18:15
40 |
41LL | let _s = s.to_owned();
42 | ^^^^^^^^^^^ help: remove this
43 |
44note: this value is dropped without further use
45 --> $DIR/redundant_clone.rs:18:14
46 |
47LL | let _s = s.to_owned();
48 | ^
49
50error: redundant clone
51 --> $DIR/redundant_clone.rs:20:42
52 |
53LL | let _s = Path::new("/a/b/").join("c").to_owned();
54 | ^^^^^^^^^^^ help: remove this
55 |
56note: this value is dropped without further use
57 --> $DIR/redundant_clone.rs:20:14
58 |
59LL | let _s = Path::new("/a/b/").join("c").to_owned();
60 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
61
62error: redundant clone
63 --> $DIR/redundant_clone.rs:22:42
64 |
65LL | let _s = Path::new("/a/b/").join("c").to_path_buf();
66 | ^^^^^^^^^^^^^^ help: remove this
67 |
68note: this value is dropped without further use
69 --> $DIR/redundant_clone.rs:22:14
70 |
71LL | let _s = Path::new("/a/b/").join("c").to_path_buf();
72 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
73
74error: redundant clone
75 --> $DIR/redundant_clone.rs:24:29
76 |
77LL | let _s = OsString::new().to_owned();
78 | ^^^^^^^^^^^ help: remove this
79 |
80note: this value is dropped without further use
81 --> $DIR/redundant_clone.rs:24:14
82 |
83LL | let _s = OsString::new().to_owned();
84 | ^^^^^^^^^^^^^^^
85
86error: redundant clone
87 --> $DIR/redundant_clone.rs:26:29
88 |
89LL | let _s = OsString::new().to_os_string();
90 | ^^^^^^^^^^^^^^^ help: remove this
91 |
92note: this value is dropped without further use
93 --> $DIR/redundant_clone.rs:26:14
94 |
95LL | let _s = OsString::new().to_os_string();
96 | ^^^^^^^^^^^^^^^
97
98error: redundant clone
99 --> $DIR/redundant_clone.rs:33:19
100 |
101LL | let _t = tup.0.clone();
102 | ^^^^^^^^ help: remove this
103 |
104note: this value is dropped without further use
105 --> $DIR/redundant_clone.rs:33:14
106 |
107LL | let _t = tup.0.clone();
108 | ^^^^^
109
110error: redundant clone
111 --> $DIR/redundant_clone.rs:62:25
112 |
113LL | if b { (a.clone(), a.clone()) } else { (Alpha, a) }
114 | ^^^^^^^^ help: remove this
115 |
116note: this value is dropped without further use
117 --> $DIR/redundant_clone.rs:62:24
118 |
119LL | if b { (a.clone(), a.clone()) } else { (Alpha, a) }
120 | ^
121
122error: redundant clone
123 --> $DIR/redundant_clone.rs:119:15
124 |
125LL | let _s = s.clone();
126 | ^^^^^^^^ help: remove this
127 |
128note: this value is dropped without further use
129 --> $DIR/redundant_clone.rs:119:14
130 |
131LL | let _s = s.clone();
132 | ^
133
134error: redundant clone
135 --> $DIR/redundant_clone.rs:120:15
136 |
137LL | let _t = t.clone();
138 | ^^^^^^^^ help: remove this
139 |
140note: this value is dropped without further use
141 --> $DIR/redundant_clone.rs:120:14
142 |
143LL | let _t = t.clone();
144 | ^
145
146error: redundant clone
147 --> $DIR/redundant_clone.rs:130:19
148 |
149LL | let _f = f.clone();
150 | ^^^^^^^^ help: remove this
151 |
152note: this value is dropped without further use
153 --> $DIR/redundant_clone.rs:130:18
154 |
155LL | let _f = f.clone();
156 | ^
157
158error: redundant clone
159 --> $DIR/redundant_clone.rs:142:14
160 |
161LL | let y = x.clone().join("matthias");
162 | ^^^^^^^^ help: remove this
163 |
164note: cloned value is neither consumed nor mutated
165 --> $DIR/redundant_clone.rs:142:13
166 |
167LL | let y = x.clone().join("matthias");
168 | ^^^^^^^^^
169
170error: aborting due to 14 previous errors
171