]> git.lizzy.rs Git - rust.git/blob - tests/ui/const-generics/type-dependent/type-mismatch.rs
Auto merge of #107843 - bjorn3:sync_cg_clif-2023-02-09, r=bjorn3
[rust.git] / tests / ui / const-generics / type-dependent / type-mismatch.rs
1 // revisions: full min
2 struct R;
3
4 impl R {
5     fn method<const N: u8>(&self) -> u8 { N }
6 }
7 fn main() {
8     assert_eq!(R.method::<1u16>(), 1);
9     //~^ ERROR mismatched types
10 }