File tree Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Expand file tree Collapse file tree 2 files changed +2
-7
lines changed Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ fn resize_at(capacity: uint) -> uint {
56
56
pub fn linear_map_with_capacity < K : Eq + Hash , V > (
57
57
initial_capacity : uint ) -> HashMap < K , V > {
58
58
let r = rand:: task_rng ( ) ;
59
- linear_map_with_capacity_and_keys ( r . gen ( ) , r . gen ( ) ,
59
+ linear_map_with_capacity_and_keys ( ( * r ) . gen ( ) , ( * r ) . gen ( ) ,
60
60
initial_capacity)
61
61
}
62
62
Original file line number Diff line number Diff line change @@ -688,17 +688,12 @@ pub fn task_rng() -> @IsaacRng {
688
688
}
689
689
}
690
690
691
- // Allow direct chaining with `task_rng`
692
- impl < R : Rng > Rng for @R {
693
- fn next ( & self ) -> u32 { ( * self ) . next ( ) }
694
- }
695
-
696
691
/**
697
692
* Returns a random value of a Rand type, using the task's random number
698
693
* generator.
699
694
*/
700
695
pub fn random < T : Rand > ( ) -> T {
701
- task_rng ( ) . gen ( )
696
+ ( * task_rng ( ) ) . gen ( )
702
697
}
703
698
704
699
#[ cfg( test) ]
You can’t perform that action at this time.
0 commit comments