summaryrefslogtreecommitdiffstats
path: root/src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr')
-rw-r--r--src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr b/src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr
new file mode 100644
index 000000000..0332e82fe
--- /dev/null
+++ b/src/test/ui/const-generics/generic_const_exprs/issue-83765.stderr
@@ -0,0 +1,34 @@
+error[E0308]: method not compatible with trait
+ --> $DIR/issue-83765.rs:30:5
+ |
+LL | fn size(&self) -> [usize; DIM] {
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `Self::DIM`, found `DIM`
+ |
+ = note: expected type `Self::DIM`
+ found type `DIM`
+
+error: unconstrained generic constant
+ --> $DIR/issue-83765.rs:32:24
+ |
+LL | self.reference.size()
+ | ^^^^
+ |
+ = help: try adding a `where` bound using this expression: `where [(); Self::DIM]:`
+note: required by a bound in `TensorSize::size`
+ --> $DIR/issue-83765.rs:9:31
+ |
+LL | fn size(&self) -> [usize; Self::DIM];
+ | ^^^^^^^^^ required by this bound in `TensorSize::size`
+
+error[E0308]: mismatched types
+ --> $DIR/issue-83765.rs:32:9
+ |
+LL | self.reference.size()
+ | ^^^^^^^^^^^^^^^^^^^^^ expected `DIM`, found `Self::DIM`
+ |
+ = note: expected type `DIM`
+ found type `Self::DIM`
+
+error: aborting due to 3 previous errors
+
+For more information about this error, try `rustc --explain E0308`.