2012-07-12 11:36:56 -05:00
|
|
|
enum ast {
|
2012-04-21 12:04:58 -05:00
|
|
|
num(uint),
|
|
|
|
add(&ast, &ast)
|
|
|
|
}
|
|
|
|
|
2012-07-12 11:36:56 -05:00
|
|
|
fn mk_add_bad2(x: &a/ast, y: &a/ast, z: &ast) -> ast {
|
2012-08-13 17:06:13 -05:00
|
|
|
add(x, y)
|
|
|
|
//~^ ERROR cannot infer an appropriate lifetime
|
2012-04-21 12:04:58 -05:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
2012-08-13 17:06:13 -05:00
|
|
|
}
|