]>
Commit | Line | Data |
---|---|---|
8faf50e0 XL |
1 | error[E0308]: mismatched types |
2 | --> $DIR/issue-13853.rs:24:9 | |
3 | | | |
4 | LL | fn nodes<'a, I: Iterator<Item=&'a N>>(&self) -> I | |
5 | | - expected `I` because of return type | |
6 | ... | |
7 | LL | self.iter() //~ ERROR mismatched types | |
8 | | ^^^^^^^^^^^ expected type parameter, found struct `std::slice::Iter` | |
9 | | | |
10 | = note: expected type `I` | |
11 | found type `std::slice::Iter<'_, N>` | |
12 | ||
13 | error[E0599]: no method named `iter` found for type `&G` in the current scope | |
14 | --> $DIR/issue-13853.rs:37:23 | |
15 | | | |
16 | LL | for node in graph.iter() { //~ ERROR no method named `iter` found | |
17 | | ^^^^ | |
18 | ||
19 | error[E0308]: mismatched types | |
20 | --> $DIR/issue-13853.rs:47:13 | |
21 | | | |
22 | LL | iterate(graph); //~ ERROR mismatched types | |
23 | | ^^^^^ | |
24 | | | | |
25 | | expected reference, found struct `std::vec::Vec` | |
26 | | help: consider borrowing here: `&graph` | |
27 | | | |
28 | = note: expected type `&_` | |
29 | found type `std::vec::Vec<Stuff>` | |
30 | ||
31 | error: aborting due to 3 previous errors | |
32 | ||
33 | Some errors occurred: E0308, E0599. | |
34 | For more information about an error, try `rustc --explain E0308`. |