From ad68ddf111329f3a36c8c87eb99323781902ad6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20B=C3=BChler?= <david.buhler@cea.fr> Date: Tue, 25 Oct 2022 13:04:47 +0200 Subject: [PATCH] [Dive] Fixes a typo, and minor style changes. --- src/plugins/dive/dive_graph.ml | 2 +- src/plugins/dive/node_kind.ml | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/plugins/dive/dive_graph.ml b/src/plugins/dive/dive_graph.ml index 0b3f40c3240..297e16a2b8c 100644 --- a/src/plugins/dive/dive_graph.ml +++ b/src/plugins/dive/dive_graph.ml @@ -339,7 +339,7 @@ struct let output_taint = function | Eva.Results.Direct -> `String "direct" - | Indirect -> `String "inddirect" + | Indirect -> `String "indirect" | Untainted -> `String "untainted" let output_node node = diff --git a/src/plugins/dive/node_kind.ml b/src/plugins/dive/node_kind.ml index 03db93576e5..bbec83b346e 100644 --- a/src/plugins/dive/node_kind.ml +++ b/src/plugins/dive/node_kind.ml @@ -70,7 +70,7 @@ struct Datatype.Int.compare i1 i2 | String _, _ -> 1 | _, String _ -> -1 - | Const (e1), Const(e2) -> + | Const e1, Const e2 -> Cil_datatype.Exp.compare e1 e2 | Const _, _ -> 1 | _, Const _ -> -1 @@ -90,7 +90,7 @@ struct Stmt.equal stmt1 stmt2 && Alarms.equal alarm1 alarm2 | AbsoluteMemory, AbsoluteMemory -> true | String (i,_), String (j,_) -> Datatype.Int.equal i j - | Const (e1), Const(e2) -> Cil_datatype.Exp.equal e1 e2 + | Const e1, Const e2 -> Cil_datatype.Exp.equal e1 e2 | Error s1, Error s2 -> Datatype.String.equal s1 s2 | _ -> false @@ -107,8 +107,8 @@ struct Hashtbl.hash (5, Stmt.hash stmt, Alarms.hash alarm) | AbsoluteMemory -> 6 | String (i, _) -> Hashtbl.hash (7, i) - | Const (e) -> Hashtbl.hash (7, Cil_datatype.Exp.hash e) - | Error s -> Hashtbl.hash (8, s) + | Const e -> Hashtbl.hash (8, Cil_datatype.Exp.hash e) + | Error s -> Hashtbl.hash (9, s) end include Datatype.Make (DatatypeInput) @@ -137,7 +137,7 @@ let pretty fmt = function Format.fprintf fmt "%S" s | String (_, CSWstring s) -> Format.fprintf fmt "L\"%s\"" (Escape.escape_wstring s) - | Const (e) -> + | Const e -> Format.fprintf fmt "%a" Cil_printer.pp_exp e | Error s -> Format.fprintf fmt "%s" s -- GitLab