]> git.lizzy.rs Git - rust.git/blob - tests/ui/const-generics/generic_const_exprs/issue-83765.stderr
Rollup merge of #106664 - chenyukang:yukang/fix-106597-remove-lseek, r=cuviper
[rust.git] / tests / ui / const-generics / generic_const_exprs / issue-83765.stderr
1 error[E0308]: method not compatible with trait
2   --> $DIR/issue-83765.rs:30:5
3    |
4 LL |     fn size(&self) -> [usize; DIM] {
5    |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Self::DIM`, found `DIM`
6    |
7    = note: expected constant `Self::DIM`
8               found constant `DIM`
9
10 error: unconstrained generic constant
11   --> $DIR/issue-83765.rs:32:24
12    |
13 LL |         self.reference.size()
14    |                        ^^^^
15    |
16    = help: try adding a `where` bound using this expression: `where [(); Self::DIM]:`
17 note: required by a bound in `TensorSize::size`
18   --> $DIR/issue-83765.rs:9:31
19    |
20 LL |     fn size(&self) -> [usize; Self::DIM];
21    |                               ^^^^^^^^^ required by this bound in `TensorSize::size`
22
23 error[E0308]: mismatched types
24   --> $DIR/issue-83765.rs:32:9
25    |
26 LL |         self.reference.size()
27    |         ^^^^^^^^^^^^^^^^^^^^^ expected `DIM`, found `Self::DIM`
28    |
29    = note: expected constant `DIM`
30               found constant `Self::DIM`
31
32 error: aborting due to 3 previous errors
33
34 For more information about this error, try `rustc --explain E0308`.