1 2 3 4 5 6 7 8 9 10 11 12 13
//error-pattern:x does not have object type use std; fn main() { let x = 3; let anon_obj = obj () { fn foo() -> int { ret 3; } with x }; }