We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent f77dd5a commit 10d6b34Copy full SHA for 10d6b34
src/test/ui/rust-2021/future-prelude-collision-unneeded.rs
@@ -23,11 +23,36 @@ impl Hey for X {
23
}
24
25
26
+struct Y<T>(T);
27
+
28
+impl Hey for Y<i32> {
29
+ fn from_iter(_: i32) -> Self {
30
+ Y(0)
31
+ }
32
+}
33
34
+struct Z<T>(T);
35
36
+impl Hey for Z<i32> {
37
38
+ Z(0)
39
40
41
42
+impl std::iter::FromIterator<u32> for Z<u32> {
43
+ fn from_iter<T: IntoIterator<Item = u32>>(_: T) -> Self {
44
+ todo!()
45
46
47
48
fn main() {
49
// See https://github.com/rust-lang/rust/issues/86633
50
let s = S;
51
let s2 = s.try_into();
52
53
// See https://github.com/rust-lang/rust/issues/86902
54
X::from_iter(1);
55
+ Y::from_iter(1);
56
+ Y::<i32>::from_iter(1);
57
+ Z::<i32>::from_iter(1);
58
0 commit comments