@@ -215,7 +215,7 @@ impl BigBitv {
215215}
216216
217217#[ deriving( Clone ) ]
218- enum BitvVariant { Big ( ~ BigBitv ) , Small ( ~ SmallBitv ) }
218+ enum BitvVariant { Big ( BigBitv ) , Small ( SmallBitv ) }
219219
220220enum Op { Union , Intersect , Assign , Difference }
221221
@@ -241,20 +241,20 @@ impl Bitv {
241241 match self . rep {
242242 Small ( ref mut s) => match other. rep {
243243 Small ( ref s1) => match op {
244- Union => s. union ( * s1, self . nbits ) ,
245- Intersect => s. intersect ( * s1, self . nbits ) ,
246- Assign => s. become ( * s1, self . nbits ) ,
247- Difference => s. difference ( * s1, self . nbits )
244+ Union => s. union ( s1, self . nbits ) ,
245+ Intersect => s. intersect ( s1, self . nbits ) ,
246+ Assign => s. become ( s1, self . nbits ) ,
247+ Difference => s. difference ( s1, self . nbits )
248248 } ,
249249 Big ( _) => die ( )
250250 } ,
251251 Big ( ref mut s) => match other. rep {
252252 Small ( _) => die ( ) ,
253253 Big ( ref s1) => match op {
254- Union => s. union ( * s1, self . nbits ) ,
255- Intersect => s. intersect ( * s1, self . nbits ) ,
256- Assign => s. become ( * s1, self . nbits ) ,
257- Difference => s. difference ( * s1, self . nbits )
254+ Union => s. union ( s1, self . nbits ) ,
255+ Intersect => s. intersect ( s1, self . nbits ) ,
256+ Assign => s. become ( s1, self . nbits ) ,
257+ Difference => s. difference ( s1, self . nbits )
258258 }
259259 }
260260 }
@@ -265,14 +265,14 @@ impl Bitv {
265265impl Bitv {
266266 pub fn new ( nbits : uint , init : bool ) -> Bitv {
267267 let rep = if nbits <= uint:: bits {
268- Small ( ~ SmallBitv :: new ( if init { !0 } else { 0 } ) )
268+ Small ( SmallBitv :: new ( if init { !0 } else { 0 } ) )
269269 }
270270 else {
271271 let nelems = nbits/uint:: bits +
272272 if nbits % uint:: bits == 0 { 0 } else { 1 } ;
273273 let elem = if init { !0 u} else { 0 u} ;
274274 let s = vec:: from_elem ( nelems, elem) ;
275- Big ( ~ BigBitv :: new ( s) )
275+ Big ( BigBitv :: new ( s) )
276276 } ;
277277 Bitv { rep : rep, nbits : nbits}
278278 }
@@ -341,11 +341,11 @@ impl Bitv {
341341 if self . nbits != v1. nbits { return false ; }
342342 match self . rep {
343343 Small ( ref b) => match v1. rep {
344- Small ( ref b1) => b. equals ( * b1, self . nbits ) ,
344+ Small ( ref b1) => b. equals ( b1, self . nbits ) ,
345345 _ => false
346346 } ,
347347 Big ( ref s) => match v1. rep {
348- Big ( ref s1) => s. equals ( * s1, self . nbits ) ,
348+ Big ( ref s1) => s. equals ( s1, self . nbits ) ,
349349 Small ( _) => return false
350350 }
351351 }
@@ -614,8 +614,8 @@ impl BitvSet {
614614 }
615615 let Bitv { rep, _} = bitv;
616616 match rep {
617- Big ( ~ b) => BitvSet { size : size, bitv : b } ,
618- Small ( ~ SmallBitv { bits} ) =>
617+ Big ( b) => BitvSet { size : size, bitv : b } ,
618+ Small ( SmallBitv { bits} ) =>
619619 BitvSet { size : size, bitv : BigBitv { storage : ~[ bits] } } ,
620620 }
621621 }
@@ -628,7 +628,7 @@ impl BitvSet {
628628 pub fn unwrap ( self ) -> Bitv {
629629 let cap = self . capacity ( ) ;
630630 let BitvSet { bitv, _} = self ;
631- return Bitv { nbits : cap, rep : Big ( ~ bitv) } ;
631+ return Bitv { nbits : cap, rep : Big ( bitv) } ;
632632 }
633633
634634 #[ inline]
0 commit comments