@@ -92,14 +92,12 @@ fn test_tls_multitask() {
9292 fn my_key ( _x : @~str ) { }
9393 local_data_set ( my_key, @~"parent data") ;
9494 do task:: spawn {
95- unsafe {
96- // TLS shouldn't carry over.
97- assert!( local_data_get ( my_key) . is_none ( ) ) ;
98- local_data_set ( my_key, @~"child data") ;
99- assert ! ( * ( local_data_get( my_key) . get( ) ) ==
95+ // TLS shouldn't carry over.
96+ assert!( local_data_get ( my_key) . is_none ( ) ) ;
97+ local_data_set ( my_key, @~"child data") ;
98+ assert ! ( * ( local_data_get( my_key) . get( ) ) ==
10099 ~"child data");
101- // should be cleaned up for us
102- }
100+ // should be cleaned up for us
103101 }
104102 // Must work multiple times
105103 assert!(*(local_data_get(my_key).get()) == ~" parent data");
@@ -206,12 +204,11 @@ fn test_tls_cleanup_on_failure() {
206204 local_data_set(str_key, @~" parent data");
207205 local_data_set(box_key, @@());
208206 do task::spawn {
209- unsafe { // spawn_linked
210- local_data_set(str_key, @~" string data") ;
211- local_data_set( box_key, @@( ) ) ;
212- local_data_set( int_key, @42 ) ;
213- fail!( ) ;
214- }
207+ // spawn_linked
208+ local_data_set(str_key, @~" string data") ;
209+ local_data_set( box_key, @@( ) ) ;
210+ local_data_set( int_key, @42 ) ;
211+ fail!( ) ;
215212 }
216213 // Not quite nondeterministic.
217214 local_data_set( int_key, @31337 ) ;
0 commit comments