diff options
| author | Jorge Aparicio <japaricious@gmail.com> | 2014-12-30 18:05:17 -0500 |
|---|---|---|
| committer | Jorge Aparicio <japaricious@gmail.com> | 2014-12-31 22:50:25 -0500 |
| commit | 371f04d4330f70cfab5fa2a5fdb65df7ccd0604c (patch) | |
| tree | 501d58736b4db70155b452b58d39fc658721ef6f /src/libstd/io | |
| parent | a17c2b60e1c32e950b011296025a9f88f4d3c4e4 (diff) | |
| download | rust-371f04d4330f70cfab5fa2a5fdb65df7ccd0604c.tar.gz rust-371f04d4330f70cfab5fa2a5fdb65df7ccd0604c.zip | |
std: unbox closures used in function arguments
Diffstat (limited to 'src/libstd/io')
| -rw-r--r-- | src/libstd/io/stdio.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/libstd/io/stdio.rs b/src/libstd/io/stdio.rs index 43d2e078035..b7d069eb19e 100644 --- a/src/libstd/io/stdio.rs +++ b/src/libstd/io/stdio.rs @@ -334,7 +334,7 @@ pub fn set_stderr(stderr: Box<Writer + Send>) -> Option<Box<Writer + Send>> { // // io1 aliases io2 // }) // }) -fn with_task_stdout(f: |&mut Writer| -> IoResult<()>) { +fn with_task_stdout<F>(f: F) where F: FnOnce(&mut Writer) -> IoResult<()> { let mut my_stdout = LOCAL_STDOUT.with(|slot| { slot.borrow_mut().take() }).unwrap_or_else(|| { |
