Home My Page Projects Code Snippets Project Openings SML/NJ
 Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Diff of /MLRISC/trunk/ra/raBitset.sml
 [smlnj] / MLRISC / trunk / ra / raBitset.sml

Diff of /MLRISC/trunk/ra/raBitset.sml

revision 245, Sat Apr 17 18:47:12 1999 UTC revision 411, Fri Sep 3 00:25:03 1999 UTC
# Line 20  Line 20
20      val new         : int -> bitMatrix      val new         : int -> bitMatrix
21      val add         : bitMatrix -> (int * int) -> bool      val add         : bitMatrix -> (int * int) -> bool
22      val member      : bitMatrix -> (int * int) -> bool      val member      : bitMatrix -> (int * int) -> bool
23  (*  val delete      : bitMatrix -> (int * int) -> unit      val delete      : bitMatrix -> (int * int) -> bool
24      val clear       : bitMatrix * int -> unit  (*  val clear       : bitMatrix * int -> unit
25  *)  *)
26  end  end
27
# Line 113  Line 113
113        | find(B(i',j',b)) =        | find(B(i',j',b)) =
114            if i=i' andalso j=j' then (elems := !elems-1; b) else B(i',j',find b)            if i=i' andalso j=j' then (elems := !elems-1; b) else B(i',j',find b)
115      val indx = moduloSize(i, j, shift, !size)      val indx = moduloSize(i, j, shift, !size)
116    in Unsafe.Array.update(table, indx, find(Array.sub(table,indx)))      val n = !elems
117      in Unsafe.Array.update(table, indx, find(Array.sub(table,indx)));
118         !elems <> n (* changed? *)
119    end    end
120
121    fun clear (INTPAIRMAP{table,elems,original,size, ...}, _) = let    fun clear (INTPAIRMAP{table,elems,original,size, ...}, _) = let
# Line 126  Line 128
128    end    end
129  end  end
130
(*
* \$Log: raBitset.sml,v \$
* Revision 1.1.1.1  1998/04/08 18:39:02  george
* Version 110.5
*
*)

Legend:
 Removed from v.245 changed lines Added in v.411