Make alias analysis properly recognize closures in call position
I figured this'd break a few things, but in fact it causes no problems whatsoever.
This commit is contained in:
parent
6ba4eacddf
commit
fb196e6ef1
1 changed files with 1 additions and 1 deletions
|
@ -181,7 +181,7 @@ fn check_call(cx: &ctx, f: &@ast::expr, args: &[@ast::expr], sc: &scope)
|
|||
}
|
||||
let f_may_close = alt f.node {
|
||||
ast::expr_path(_) { def_is_local(cx.tcx.def_map.get(f.id), true) }
|
||||
_ { false } // FIXME should be true!
|
||||
_ { true }
|
||||
};
|
||||
if f_may_close {
|
||||
let i = 0u;
|
||||
|
|
Loading…
Add table
Reference in a new issue