rust/tests/ui/associated-consts/assoc-const-ty-mismatch.stderr

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

31 lines
854 B
Plaintext
Raw Normal View History

error: expected constant, found type
--> $DIR/assoc-const-ty-mismatch.rs:23:19
|
LL | fn foo<F: Foo<N = usize>>() {}
| - ^^^^^ unexpected type
| |
| expected a constant because of this associated constant
2022-02-01 09:28:31 -06:00
|
note: the associated constant is defined here
--> $DIR/assoc-const-ty-mismatch.rs:5:5
2022-02-01 09:28:31 -06:00
|
LL | const N: usize;
| ^^^^^^^^^^^^^^
error: expected type, found constant
--> $DIR/assoc-const-ty-mismatch.rs:25:22
|
LL | fn foo2<F: FooTy<T = 3usize>>() {}
| - ^^^^^^ unexpected constant
| |
| expected a type because of this associated type
2022-02-01 09:28:31 -06:00
|
note: the associated type is defined here
--> $DIR/assoc-const-ty-mismatch.rs:9:5
2022-02-01 09:28:31 -06:00
|
LL | type T;
| ^^^^^^
error: aborting due to 2 previous errors