File tree 2 files changed +20
-0
lines changed
2 files changed +20
-0
lines changed Original file line number Diff line number Diff line change 46
46
#[ doc( no_inline) ] pub use ops:: { Drop , Deref , DerefMut } ;
47
47
#[ doc( no_inline) ] pub use ops:: { Shl , Shr } ;
48
48
#[ doc( no_inline) ] pub use ops:: { Index , IndexMut } ;
49
+ #[ doc( no_inline) ] pub use ops:: { Fn , FnMut , FnOnce } ;
49
50
#[ doc( no_inline) ] pub use option:: { Option , Some , None } ;
50
51
#[ doc( no_inline) ] pub use result:: { Result , Ok , Err } ;
51
52
Original file line number Diff line number Diff line change
1
+ // Copyright 2014 The Rust Project Developers. See the COPYRIGHT
2
+ // file at the top-level directory of this distribution and at
3
+ // http://rust-lang.org/COPYRIGHT.
4
+ //
5
+ // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
6
+ // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
7
+ // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
8
+ // option. This file may not be copied, modified, or distributed
9
+ // except according to those terms.
10
+
11
+ // Tests that the reexports of `FnOnce` et al from the prelude work.
12
+
13
+ #![ feature( unboxed_closures, unboxed_closure_sugar) ]
14
+
15
+ fn main ( ) {
16
+ let task: Box < |: int| -> int > = box |: x| x;
17
+ task. call_once ( ( 0 i, ) ) ;
18
+ }
19
+
You can’t perform that action at this time.
0 commit comments