summaryrefslogtreecommitdiffstats
path: root/src/test/ui/generic-associated-types/const_params_have_right_type.stderr
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/generic-associated-types/const_params_have_right_type.stderr')
-rw-r--r--src/test/ui/generic-associated-types/const_params_have_right_type.stderr16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/test/ui/generic-associated-types/const_params_have_right_type.stderr b/src/test/ui/generic-associated-types/const_params_have_right_type.stderr
new file mode 100644
index 000000000..89c993dee
--- /dev/null
+++ b/src/test/ui/generic-associated-types/const_params_have_right_type.stderr
@@ -0,0 +1,16 @@
+error[E0053]: type `Foo` has an incompatible generic parameter for trait `Trait`
+ --> $DIR/const_params_have_right_type.rs:8:14
+ |
+LL | trait Trait {
+ | -----
+LL | type Foo<const N: u8>;
+ | ----------- expected const parameter of type `u8`
+...
+LL | impl Trait for () {
+ | -----------------
+LL | type Foo<const N: u64> = u32;
+ | ^^^^^^^^^^^^ found const parameter of type `u64`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0053`.