diff options
| author | Patrick Walton <pcwalton@mimiga.net> | 2013-11-21 23:36:52 -0800 |
|---|---|---|
| committer | Patrick Walton <pcwalton@mimiga.net> | 2013-11-26 08:25:27 -0800 |
| commit | 749ee53c6d23ae1467568d6e0280a4f59e4e952b (patch) | |
| tree | 8ff17ad29a91e3b5d625db08d2d7d9e039ed484a /src/libstd/rt/mod.rs | |
| parent | 38efa17bb8b9c1077e7b8cd9d67da08dec3f0bda (diff) | |
| download | rust-749ee53c6d23ae1467568d6e0280a4f59e4e952b.tar.gz rust-749ee53c6d23ae1467568d6e0280a4f59e4e952b.zip | |
librustc: Make `||` lambdas not infer to `proc`s
Diffstat (limited to 'src/libstd/rt/mod.rs')
| -rw-r--r-- | src/libstd/rt/mod.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libstd/rt/mod.rs b/src/libstd/rt/mod.rs index ad5c69e9a0c..a8b510cbed7 100644 --- a/src/libstd/rt/mod.rs +++ b/src/libstd/rt/mod.rs @@ -340,14 +340,14 @@ fn run_(main: proc(), use_main_sched: bool) -> int { // When the main task exits, after all the tasks in the main // task tree, shut down the schedulers and set the exit code. - let handles = Cell::new(handles); - let on_exit: proc(UnwindResult) = |exit_success| { + let handles = handles; + let on_exit: proc(UnwindResult) = proc(exit_success) { unsafe { assert!(!(*exited_already.get()).swap(true, SeqCst), "the runtime already exited"); } - let mut handles = handles.take(); + let mut handles = handles; for handle in handles.mut_iter() { handle.send(Shutdown); } |
