2014-11-27 06:59:21 -05:00
|
|
|
// Test that parentheses form doesn't work with struct types appearing in argument types.
|
|
|
|
|
2015-01-12 10:27:25 -05:00
|
|
|
struct Bar<A> {
|
|
|
|
f: A
|
2014-11-27 06:59:21 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn foo(b: Box<Bar()>) {
|
2019-01-20 02:45:38 -08:00
|
|
|
//~^ ERROR parenthesized type parameters may only be used with a `Fn` trait
|
2023-02-23 10:27:06 -07:00
|
|
|
//~| ERROR struct takes 1 generic argument but 0 generic arguments
|
2014-11-27 06:59:21 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() { }
|