1
1
//@ compile-flags: -Znormalize-docs
2
+ //@ dont-require-annotations: NOTE
3
+
2
4
// https://github.com/rust-lang/rust/issues/105742
3
5
use std:: ops:: Index ;
4
6
5
7
pub fn next < ' a , T > ( s : & ' a mut dyn SVec < Item = T , Output = T > ) {
6
- //~^ expected 1 lifetime argument
7
- //~| expected 1 generic argument
8
+ //~^ NOTE expected 1 lifetime argument
9
+ //~| NOTE expected 1 generic argument
8
10
//~| ERROR the trait `SVec` is not dyn compatible
9
- //~| `SVec` is not dyn compatible
11
+ //~| NOTE `SVec` is not dyn compatible
10
12
//~| ERROR missing generics for associated type `SVec::Item`
11
13
//~| ERROR missing generics for associated type `SVec::Item`
12
14
let _ = s;
13
15
}
14
16
15
17
pub trait SVec : Index <
16
18
<Self as SVec >:: Item ,
17
- //~^ expected 1 lifetime argument
18
- //~| expected 1 generic argument
19
+ //~^ NOTE expected 1 lifetime argument
20
+ //~| NOTE expected 1 generic argument
19
21
//~| ERROR missing generics for associated type `SVec::Item`
20
22
//~| ERROR missing generics for associated type `SVec::Item`
21
23
//~| ERROR missing generics for associated type `SVec::Item`
@@ -25,8 +27,8 @@ pub trait SVec: Index<
25
27
//~| ERROR missing generics for associated type `SVec::Item`
26
28
//~| ERROR missing generics for associated type `SVec::Item`
27
29
Output = <Index < <Self as SVec >:: Item ,
28
- //~^ expected 1 lifetime argument
29
- //~| expected 1 generic argument
30
+ //~^ NOTE expected 1 lifetime argument
31
+ //~| NOTE expected 1 generic argument
30
32
//~| ERROR missing generics for associated type `SVec::Item`
31
33
//~| ERROR missing generics for associated type `SVec::Item`
32
34
//~| ERROR missing generics for associated type `SVec::Item`
@@ -36,16 +38,16 @@ pub trait SVec: Index<
36
38
//~| ERROR missing generics for associated type `SVec::Item`
37
39
//~| ERROR missing generics for associated type `SVec::Item`
38
40
Output = <Self as SVec >:: Item > as SVec >:: Item ,
39
- //~^ expected 1 lifetime argument
40
- //~| expected 1 generic argument
41
- //~| expected 1 lifetime argument
41
+ //~^ NOTE expected 1 lifetime argument
42
+ //~| NOTE expected 1 generic argument
43
+ //~| NOTE expected 1 lifetime argument
42
44
//~| ERROR missing generics for associated type `SVec::Item`
43
45
//~| ERROR missing generics for associated type `SVec::Item`
44
46
//~| ERROR missing generics for associated type `SVec::Item`
45
47
//~| ERROR missing generics for associated type `SVec::Item`
46
48
//~| ERROR missing generics for associated type `SVec::Item`
47
49
//~| ERROR missing generics for associated type `SVec::Item`
48
- //~| expected 1 generic argument
50
+ //~| NOTE expected 1 generic argument
49
51
//~| ERROR missing generics for associated type `SVec::Item`
50
52
//~| ERROR missing generics for associated type `SVec::Item`
51
53
//~| ERROR missing generics for associated type `SVec::Item`
@@ -60,8 +62,8 @@ pub trait SVec: Index<
60
62
type Item < ' a , T > ;
61
63
62
64
fn len ( & self ) -> <Self as SVec >:: Item ;
63
- //~^ expected 1 lifetime argument
65
+ //~^ NOTE expected 1 lifetime argument
64
66
//~| ERROR missing generics for associated type `SVec::Item`
65
- //~| expected 1 generic argument
67
+ //~| NOTE expected 1 generic argument
66
68
//~| ERROR missing generics for associated type `SVec::Item`
67
69
}
0 commit comments