rust/tests/ui/type-inference/unbounded-type-param-in-fn-...

10 lines
146 B
Rust

#[allow(invalid_type_param_default)]
fn foo<T, U = u64>() -> (T, U) {
panic!()
}
fn main() {
foo(); //~ ERROR type annotations needed
}