@@ -572,7 +572,7 @@ mod tests {
572572 #[ test] #[ should_fail] #[ ignore( cfg( windows) ) ]
573573 pub fn test_rw_arc_poison_wr( ) {
574574 let arc = ~RWARC ( 1 ) ;
575- let arc2 = ~ arc. clone( ) ;
575+ let arc2 = ( * arc) . clone( ) ;
576576 do task:: try || {
577577 do arc2. write |one| {
578578 fail_unless!( * one == 2 ) ;
@@ -585,7 +585,7 @@ mod tests {
585585 #[ test] #[ should_fail] #[ ignore( cfg( windows) ) ]
586586 pub fn test_rw_arc_poison_ww( ) {
587587 let arc = ~RWARC ( 1 ) ;
588- let arc2 = ~ arc. clone( ) ;
588+ let arc2 = ( * arc) . clone( ) ;
589589 do task:: try || {
590590 do arc2. write |one| {
591591 fail_unless!( * one == 2 ) ;
@@ -598,7 +598,7 @@ mod tests {
598598 #[ test] #[ should_fail] #[ ignore( cfg( windows) ) ]
599599 pub fn test_rw_arc_poison_dw( ) {
600600 let arc = ~RWARC ( 1 ) ;
601- let arc2 = ~ arc. clone( ) ;
601+ let arc2 = ( * arc) . clone( ) ;
602602 do task:: try || {
603603 do arc2. write_downgrade |write_mode| {
604604 do ( & write_mode) . write |one| {
@@ -613,7 +613,7 @@ mod tests {
613613 #[ test] #[ ignore( cfg( windows) ) ]
614614 pub fn test_rw_arc_no_poison_rr( ) {
615615 let arc = ~RWARC ( 1 ) ;
616- let arc2 = ~ arc. clone( ) ;
616+ let arc2 = ( * arc) . clone( ) ;
617617 do task:: try || {
618618 do arc2. read |one| {
619619 fail_unless!( * one == 2 ) ;
@@ -626,7 +626,7 @@ mod tests {
626626 #[ test] #[ ignore( cfg( windows) ) ]
627627 pub fn test_rw_arc_no_poison_rw( ) {
628628 let arc = ~RWARC ( 1 ) ;
629- let arc2 = ~ arc. clone( ) ;
629+ let arc2 = ( * arc) . clone( ) ;
630630 do task:: try || {
631631 do arc2. read |one| {
632632 fail_unless!( * one == 2 ) ;
@@ -639,7 +639,7 @@ mod tests {
639639 #[ test] #[ ignore( cfg( windows) ) ]
640640 pub fn test_rw_arc_no_poison_dr( ) {
641641 let arc = ~RWARC ( 1 ) ;
642- let arc2 = ~ arc. clone( ) ;
642+ let arc2 = ( * arc) . clone( ) ;
643643 do task:: try || {
644644 do arc2. write_downgrade |write_mode| {
645645 let read_mode = arc2. downgrade( write_mode) ;
@@ -655,7 +655,7 @@ mod tests {
655655 #[ test]
656656 pub fn test_rw_arc( ) {
657657 let arc = ~RWARC ( 0 ) ;
658- let arc2 = ~ arc. clone( ) ;
658+ let arc2 = ( * arc) . clone( ) ;
659659 let ( p, c) = comm:: stream( ) ;
660660
661661 do task:: spawn || {
@@ -673,7 +673,7 @@ mod tests {
673673 // Readers try to catch the writer in the act
674674 let mut children = ~[ ] ;
675675 for 5 . times {
676- let arc3 = ~ arc. clone( ) ;
676+ let arc3 = ( * arc) . clone( ) ;
677677 do task:: task( ) . future_result( |+r| children. push( r) ) . spawn
678678 || {
679679 do arc3. read |num| {
@@ -704,7 +704,7 @@ mod tests {
704704 for 10 . times {
705705 let ( ( rp1, rc1) , ( rp2, rc2) ) = ( comm:: stream( ) , comm:: stream( ) ) ;
706706 reader_convos. push( ( rc1, rp2) ) ;
707- let arcn = ~ arc. clone( ) ;
707+ let arcn = ( * arc) . clone( ) ;
708708 do task:: spawn || {
709709 rp1. recv( ) ; // wait for downgrader to give go-ahead
710710 do arcn. read |state| {
@@ -715,7 +715,7 @@ mod tests {
715715 }
716716
717717 // Writer task
718- let arc2 = ~ arc. clone( ) ;
718+ let arc2 = ( * arc) . clone( ) ;
719719 let ( ( wp1, wc1) , ( wp2, wc2) ) = ( comm:: stream( ) , comm:: stream( ) ) ;
720720 do task:: spawn || {
721721 wp1. recv( ) ;
0 commit comments