]> git.lizzy.rs Git - rust.git/blob - tests/ui/generic-associated-types/parse/trait-path-missing-gen_arg.stderr
Rollup merge of #103702 - WaffleLapkin:lift-sized-bounds-from-pointer-methods-where...
[rust.git] / tests / ui / generic-associated-types / parse / trait-path-missing-gen_arg.stderr
1 error: expected one of `>`, a const expression, lifetime, or type, found `:`
2   --> $DIR/trait-path-missing-gen_arg.rs:6:30
3    |
4 LL |   fn f1<'a>(arg : Box<dyn X< : 32 >>) {}
5    |                              ^ expected one of `>`, a const expression, lifetime, or type
6    |
7 help: expressions must be enclosed in braces to be used as const generic arguments
8    |
9 LL |   fn f1<'a>(arg : Box<{ dyn X< : 32 } >>) {}
10    |                       +             +
11
12 error: expected parameter name, found `>`
13   --> $DIR/trait-path-missing-gen_arg.rs:6:36
14    |
15 LL |   fn f1<'a>(arg : Box<dyn X< : 32 >>) {}
16    |                                    ^ expected parameter name
17
18 error: expected one of `!`, `)`, `+`, `,`, or `::`, found `>`
19   --> $DIR/trait-path-missing-gen_arg.rs:6:36
20    |
21 LL |   fn f1<'a>(arg : Box<dyn X< : 32 >>) {}
22    |                                    ^
23    |                                    |
24    |                                    expected one of `!`, `)`, `+`, `,`, or `::`
25    |                                    help: missing `,`
26
27 error: expected one of `>`, a const expression, lifetime, or type, found `=`
28   --> $DIR/trait-path-missing-gen_arg.rs:14:30
29    |
30 LL |   fn f1<'a>(arg : Box<dyn X< = 32 >>) {}
31    |                            - ^ expected one of `>`, a const expression, lifetime, or type
32    |                            |
33    |                            maybe try to close unmatched angle bracket
34
35 error[E0747]: constant provided when a type was expected
36   --> $DIR/trait-path-missing-gen_arg.rs:6:23
37    |
38 LL |   fn f1<'a>(arg : Box<dyn X< : 32 >>) {}
39    |                       ^^^^^^^^^^^
40
41 error: aborting due to 5 previous errors
42
43 For more information about this error, try `rustc --explain E0747`.