]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/generic_const_exprs/issue-72787.min.stderr
Highlight conflicting param-env candidates, again
[rust.git] / src / test / ui / const-generics / generic_const_exprs / issue-72787.min.stderr
1 error: generic parameters may not be used in const operations
2   --> $DIR/issue-72787.rs:11:17
3    |
4 LL |     Condition<{ LHS <= RHS }>: True
5    |                 ^^^ cannot perform const operation using `LHS`
6    |
7    = help: const parameters may only be used as standalone arguments, i.e. `LHS`
8    = help: use `#![feature(generic_const_exprs)]` to allow generic const expressions
9
10 error: generic parameters may not be used in const operations
11   --> $DIR/issue-72787.rs:11:24
12    |
13 LL |     Condition<{ LHS <= RHS }>: True
14    |                        ^^^ cannot perform const operation using `RHS`
15    |
16    = help: const parameters may only be used as standalone arguments, i.e. `RHS`
17    = help: use `#![feature(generic_const_exprs)]` to allow generic const expressions
18
19 error: generic parameters may not be used in const operations
20   --> $DIR/issue-72787.rs:25:25
21    |
22 LL |     IsLessOrEqual<{ 8 - I }, { 8 - J }>: True,
23    |                         ^ cannot perform const operation using `I`
24    |
25    = help: const parameters may only be used as standalone arguments, i.e. `I`
26    = help: use `#![feature(generic_const_exprs)]` to allow generic const expressions
27
28 error: generic parameters may not be used in const operations
29   --> $DIR/issue-72787.rs:25:36
30    |
31 LL |     IsLessOrEqual<{ 8 - I }, { 8 - J }>: True,
32    |                                    ^ cannot perform const operation using `J`
33    |
34    = help: const parameters may only be used as standalone arguments, i.e. `J`
35    = help: use `#![feature(generic_const_exprs)]` to allow generic const expressions
36
37 error[E0283]: type annotations needed: cannot satisfy `IsLessOrEqual<I, 8>: True`
38   --> $DIR/issue-72787.rs:21:26
39    |
40 LL |     IsLessOrEqual<I, 8>: True,
41    |                          ^^^^
42    |
43 note: multiple `impl`s or `where` clauses satisfying `IsLessOrEqual<I, 8>: True` found
44   --> $DIR/issue-72787.rs:10:1
45    |
46 LL | impl<const LHS: u32, const RHS: u32> True for IsLessOrEqual<LHS, RHS> where
47    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
48 ...
49 LL |     IsLessOrEqual<I, 8>: True,
50    |                          ^^^^
51 ...
52 LL |     IsLessOrEqual<{ 8 - I }, { 8 - J }>: True,
53    |                                          ^^^^
54
55 error[E0283]: type annotations needed: cannot satisfy `IsLessOrEqual<I, 8>: True`
56   --> $DIR/issue-72787.rs:21:26
57    |
58 LL |     IsLessOrEqual<I, 8>: True,
59    |                          ^^^^
60    |
61 note: multiple `impl`s or `where` clauses satisfying `IsLessOrEqual<I, 8>: True` found
62   --> $DIR/issue-72787.rs:10:1
63    |
64 LL | impl<const LHS: u32, const RHS: u32> True for IsLessOrEqual<LHS, RHS> where
65    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
66 ...
67 LL |     IsLessOrEqual<I, 8>: True,
68    |                          ^^^^
69 ...
70 LL |     IsLessOrEqual<{ 8 - I }, { 8 - J }>: True,
71    |                                          ^^^^
72
73 error: aborting due to 6 previous errors
74
75 For more information about this error, try `rustc --explain E0283`.