summary refs log tree commit diff
path: root/src/test/run-pass/lambda-infer-unresolved.rs
blob: ceb91791fa0f614ee648cf1ffa1a9962cb11f93b (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 = @{mut refs: ~[], n: 0};
    let f = fn@ () { log(error, e.n); };
    e.refs += ~[1];
}