]>
Commit | Line | Data |
---|---|---|
b7449926 | 1 | error[E0308]: mismatched types |
0731742a | 2 | --> $DIR/substs-ppaux.rs:16:17 |
b7449926 | 3 | | |
416331ca XL |
4 | LL | fn bar<'a, T>() where T: 'a {} |
5 | | --------------------------- fn() {<i8 as Foo<'static, 'static, u8>>::bar::<'static, char>} defined here | |
6 | ... | |
b7449926 | 7 | LL | let x: () = <i8 as Foo<'static, 'static, u8>>::bar::<'static, char>; |
ba9703b0 XL |
8 | | -- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `()`, found fn item |
9 | | | | |
60c5eb7d | 10 | | expected due to this |
b7449926 | 11 | | |
60c5eb7d XL |
12 | = note: expected unit type `()` |
13 | found fn item `fn() {<i8 as Foo<'static, 'static, u8>>::bar::<'static, char>}` | |
f2b60f7d | 14 | help: use parentheses to call this associated function |
ba9703b0 XL |
15 | | |
16 | LL | let x: () = <i8 as Foo<'static, 'static, u8>>::bar::<'static, char>(); | |
94222f64 | 17 | | ++ |
b7449926 XL |
18 | |
19 | error[E0308]: mismatched types | |
0731742a | 20 | --> $DIR/substs-ppaux.rs:25:17 |
b7449926 | 21 | | |
416331ca XL |
22 | LL | fn bar<'a, T>() where T: 'a {} |
23 | | --------------------------- fn() {<i8 as Foo<'static, 'static>>::bar::<'static, char>} defined here | |
24 | ... | |
b7449926 | 25 | LL | let x: () = <i8 as Foo<'static, 'static, u32>>::bar::<'static, char>; |
ba9703b0 XL |
26 | | -- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `()`, found fn item |
27 | | | | |
60c5eb7d | 28 | | expected due to this |
b7449926 | 29 | | |
60c5eb7d XL |
30 | = note: expected unit type `()` |
31 | found fn item `fn() {<i8 as Foo<'static, 'static>>::bar::<'static, char>}` | |
f2b60f7d | 32 | help: use parentheses to call this associated function |
ba9703b0 XL |
33 | | |
34 | LL | let x: () = <i8 as Foo<'static, 'static, u32>>::bar::<'static, char>(); | |
94222f64 | 35 | | ++ |
b7449926 XL |
36 | |
37 | error[E0308]: mismatched types | |
0731742a | 38 | --> $DIR/substs-ppaux.rs:33:17 |
b7449926 | 39 | | |
416331ca XL |
40 | LL | fn baz() {} |
41 | | -------- fn() {<i8 as Foo<'static, 'static, u8>>::baz} defined here | |
42 | ... | |
b7449926 | 43 | LL | let x: () = <i8 as Foo<'static, 'static, u8>>::baz; |
ba9703b0 XL |
44 | | -- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `()`, found fn item |
45 | | | | |
60c5eb7d | 46 | | expected due to this |
b7449926 | 47 | | |
60c5eb7d XL |
48 | = note: expected unit type `()` |
49 | found fn item `fn() {<i8 as Foo<'static, 'static, u8>>::baz}` | |
f2b60f7d | 50 | help: use parentheses to call this associated function |
ba9703b0 XL |
51 | | |
52 | LL | let x: () = <i8 as Foo<'static, 'static, u8>>::baz(); | |
94222f64 | 53 | | ++ |
b7449926 XL |
54 | |
55 | error[E0308]: mismatched types | |
0731742a | 56 | --> $DIR/substs-ppaux.rs:41:17 |
b7449926 | 57 | | |
416331ca XL |
58 | LL | fn foo<'z>() where &'z (): Sized { |
59 | | -------------------------------- fn() {foo::<'static>} defined here | |
60 | ... | |
b7449926 | 61 | LL | let x: () = foo::<'static>; |
ba9703b0 XL |
62 | | -- ^^^^^^^^^^^^^^ expected `()`, found fn item |
63 | | | | |
60c5eb7d | 64 | | expected due to this |
b7449926 | 65 | | |
60c5eb7d XL |
66 | = note: expected unit type `()` |
67 | found fn item `fn() {foo::<'static>}` | |
ba9703b0 XL |
68 | help: use parentheses to call this function |
69 | | | |
70 | LL | let x: () = foo::<'static>(); | |
94222f64 | 71 | | ++ |
b7449926 XL |
72 | |
73 | error[E0277]: the size for values of type `str` cannot be known at compilation time | |
0731742a | 74 | --> $DIR/substs-ppaux.rs:49:5 |
b7449926 XL |
75 | | |
76 | LL | <str as Foo<u8>>::bar; | |
77 | | ^^^^^^^^^^^^^^^^^^^^^ doesn't have a size known at compile-time | |
78 | | | |
1b1a35ee | 79 | = help: the trait `Sized` is not implemented for `str` |
f2b60f7d | 80 | note: required for `str` to implement `Foo<'_, '_, u8>` |
cdc7bbd5 XL |
81 | --> $DIR/substs-ppaux.rs:11:17 |
82 | | | |
83 | LL | impl<'a,'b,T,S> Foo<'a, 'b, S> for T {} | |
84 | | ^^^^^^^^^^^^^^ ^ | |
b7449926 XL |
85 | |
86 | error: aborting due to 5 previous errors | |
87 | ||
48663c56 | 88 | Some errors have detailed explanations: E0277, E0308. |
b7449926 | 89 | For more information about an error, try `rustc --explain E0277`. |