2015-08-07 12:32:14 -05:00
|
|
|
trait Trait {}
|
|
|
|
|
|
|
|
struct Foo<T:Trait> {
|
|
|
|
x: T,
|
|
|
|
}
|
|
|
|
|
|
|
|
enum Bar<T:Trait> {
|
|
|
|
ABar(isize),
|
|
|
|
BBar(T),
|
|
|
|
CBar(usize),
|
|
|
|
}
|
|
|
|
|
|
|
|
fn explode(x: Foo<u32>) {}
|
2016-03-29 12:12:31 -05:00
|
|
|
//~^ ERROR E0277
|
2015-08-07 12:32:14 -05:00
|
|
|
|
|
|
|
fn kaboom(y: Bar<f32>) {}
|
2016-03-29 12:12:31 -05:00
|
|
|
//~^ ERROR E0277
|
2015-08-07 12:32:14 -05:00
|
|
|
|
|
|
|
fn main() {
|
|
|
|
}
|