@@ -277,7 +277,7 @@ impl Builder {
277
277
// address at which our stack started).
278
278
let main = move || {
279
279
let something_around_the_top_of_the_stack = 1 ;
280
- let addr = & something_around_the_top_of_the_stack as * const isize ;
280
+ let addr = & something_around_the_top_of_the_stack as * const i32 ;
281
281
let my_stack_top = addr as usize ;
282
282
let my_stack_bottom = my_stack_top - stack_size + 1024 ;
283
283
unsafe {
@@ -802,13 +802,13 @@ mod test {
802
802
}
803
803
804
804
fn avoid_copying_the_body < F > ( spawnfn : F ) where F : FnOnce ( Thunk < ' static > ) {
805
- let ( tx, rx) = channel :: < u32 > ( ) ;
805
+ let ( tx, rx) = channel ( ) ;
806
806
807
807
let x = box 1 ;
808
- let x_in_parent = ( & * x) as * const isize as u32 ;
808
+ let x_in_parent = ( & * x) as * const i32 as usize ;
809
809
810
810
spawnfn ( Thunk :: new ( move || {
811
- let x_in_child = ( & * x) as * const isize as u32 ;
811
+ let x_in_child = ( & * x) as * const i32 as usize ;
812
812
tx. send ( x_in_child) . unwrap ( ) ;
813
813
} ) ) ;
814
814
@@ -847,8 +847,8 @@ mod test {
847
847
// climbing the task tree to dereference each ancestor. (See #1789)
848
848
// (well, it would if the constant were 8000+ - I lowered it to be more
849
849
// valgrind-friendly. try this at home, instead..!)
850
- const GENERATIONS : usize = 16 ;
851
- fn child_no ( x : usize ) -> Thunk < ' static > {
850
+ const GENERATIONS : u32 = 16 ;
851
+ fn child_no ( x : u32 ) -> Thunk < ' static > {
852
852
return Thunk :: new ( move || {
853
853
if x < GENERATIONS {
854
854
thread:: spawn ( move || child_no ( x+1 ) . invoke ( ( ) ) ) ;
0 commit comments