trait repeat { fn get() -> A; } impl @A: repeat { fn get() -> A { *self } } fn repeater(v: @A) -> repeat { // Note: owned kind is not necessary as A appears in the trait type v as repeat:: // No } fn main() { // Here, an error results as the type of y is inferred to // repeater<</3> where lt is the block. let y = { //~ ERROR reference is not valid outside of its lifetime let x: &blk/int = &3; repeater(@x) }; assert 3 == *(y.get()); //~ ERROR reference is not valid outside of its lifetime }