@@ -33,7 +33,7 @@ import comm::recv;
33
33
import comm:: send;
34
34
import comm:: methods;
35
35
36
- macro_rules! move {
36
+ macro_rules! move_out {
37
37
{ $x: expr } => { unsafe { let y <- * ptr:: addr_of( $x) ; y } }
38
38
}
39
39
@@ -151,7 +151,7 @@ mod map_reduce {
151
151
}
152
152
}
153
153
154
- enum reduce_proto < V : copy send> { emit_val( V ) , done, ref , release }
154
+ enum reduce_proto < V : copy send> { emit_val( V ) , done, addref , release }
155
155
156
156
fn start_mappers < K1 : copy send, K2 : const copy send hash_key ,
157
157
V : copy send> (
@@ -188,12 +188,12 @@ mod map_reduce {
188
188
alt pipes:: recv ( ctrl) {
189
189
ctrl_proto:: reducer ( c_, ctrl) {
190
190
c = some ( c_) ;
191
- move !{ ctrl}
191
+ move_out ! { ctrl}
192
192
}
193
193
}
194
194
}
195
195
intermediates. insert ( key, c. get ( ) ) ;
196
- send ( c. get ( ) , ref ) ;
196
+ send ( c. get ( ) , addref ) ;
197
197
}
198
198
}
199
199
send ( c. get ( ) , emit_val ( val) ) ;
@@ -232,7 +232,7 @@ mod map_reduce {
232
232
// error!{"all done"};
233
233
is_done = true ;
234
234
}
235
- ref { ref_count += 1 ; }
235
+ addref { ref_count += 1 ; }
236
236
release { ref_count -= 1 ; }
237
237
}
238
238
}
@@ -286,7 +286,7 @@ mod map_reduce {
286
286
}
287
287
ctrl = vec:: append_one(
288
288
ctrls,
289
- ctrl_proto:: server:: reducer( move ! { cc} , c) ) ;
289
+ ctrl_proto:: server:: reducer( move_out ! { cc} , c) ) ;
290
290
}
291
291
}
292
292
}
0 commit comments