summary refs log tree commit diff
path: root/src/test/run-pass/lambda-infer-unresolved.rs
blob: d526c00a99814ad456147dbdfde250ba87f40c34 (plain)
1
2
3
4
5
6
7
// This should typecheck even though the type of e is not fully
// resolved when we finish typechecking the fn@.
fn main() {
    let e = @{mutable refs: [], n: 0};
    let f = fn@ () { log(error, e.n); };
    e.refs += [1];
}