Skip to content

Commit e09ce9f

Browse files
committed
C2PO: Use CilType.Typ for equal, compare and hash in DuplicateVars.
1 parent 6ddf176 commit e09ce9f

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

src/cdomains/duplicateVars.ml

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,13 @@ module M = Messages
1313
assignment and return and duplicated variables for remembering the value of variables at the beginning of a function. *)
1414
module VarType = struct
1515
let equal_typ a b =
16-
(* TODO: Structural equality on (possibly cyclic) data type typ may not terminate in incremental analysis. *)
17-
(* Using Stdlib.(=) instead of Stdlib.compare will not terminate even in the non-incremental case. *)
18-
Stdlib.compare a b = 0
16+
CilType.Typ.equal a b
1917

2018
let hash_typ x =
21-
Hashtbl.hash x
19+
CilType.Typ.hash x
2220

2321
let compare_typ a b =
24-
(* TODO: Structural compare on (possibly cyclic) data type typ may not terminate in incremental analysis. *)
25-
Stdlib.compare a b
22+
CilType.Typ.compare a b
2623

2724
type t =
2825
| AssignAux of typ

0 commit comments

Comments
 (0)