]> git.lizzy.rs Git - rust.git/blob - src/test/ui/const-generics/type-dependent/type-mismatch.rs
Rollup merge of #73197 - c410-f3r:ranges, r=dtolnay
[rust.git] / src / test / ui / const-generics / type-dependent / type-mismatch.rs
1 #![feature(const_generics)]
2 //~^ WARN the feature `const_generics` is incomplete
3
4 struct R;
5
6 impl R {
7     fn method<const N: u8>(&self) -> u8 { N }
8 }
9 fn main() {
10     assert_eq!(R.method::<1u16>(), 1);
11     //~^ ERROR mismatched types
12 }