blob: e7a25fc7240053cfe8f356888ef4f628fcc99311 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
#![feature(type_alias_impl_trait)]
use std::fmt::Debug;
fn main() {}
// test that unused generic parameters are ok
type Two<T, U> = impl Debug;
fn two<T: Debug, U>(t: T, _: U) -> Two<T, U> {
t
//~^ ERROR `T` doesn't implement `Debug`
}
fn three<T, U: Debug>(_: T, u: U) -> Two<T, U> {
u
//~^ ERROR `U` doesn't implement `Debug`
}
|