File tree Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Expand file tree Collapse file tree 1 file changed +2
-3
lines changed Original file line number Diff line number Diff line change 1
1
#![ feature( futures_api) ]
2
2
#![ feature( optin_builtin_traits) ]
3
3
#![ feature( generator_trait) ]
4
- #![ feature( pin) ]
5
4
#![ feature( arbitrary_self_types) ]
6
5
#![ no_std]
7
6
@@ -12,7 +11,7 @@ pub mod future {
12
11
13
12
use core:: {
14
13
ops:: { Generator , GeneratorState } ,
15
- pin:: { Pin , Unpin } ,
14
+ pin:: Pin ,
16
15
ptr,
17
16
sync:: atomic:: { AtomicPtr , Ordering } ,
18
17
task:: { LocalWaker , Poll } ,
@@ -39,7 +38,7 @@ pub mod future {
39
38
type Output = T :: Return ;
40
39
fn poll ( self : Pin < & mut Self > , lw : & LocalWaker ) -> Poll < Self :: Output > {
41
40
set_task_waker ( lw, || {
42
- match unsafe { Pin :: get_mut_unchecked ( self ) . 0 . resume ( ) } {
41
+ match unsafe { Pin :: get_unchecked_mut ( self ) . 0 . resume ( ) } {
43
42
GeneratorState :: Yielded ( ( ) ) => Poll :: Pending ,
44
43
GeneratorState :: Complete ( x) => Poll :: Ready ( x) ,
45
44
}
You can’t perform that action at this time.
0 commit comments