From 96ee17897c7e4271edd296120e8af2190679e22d Mon Sep 17 00:00:00 2001 From: Josh Berdine Date: Thu, 29 Oct 2020 13:26:45 -0700 Subject: [PATCH] [sledge] Add Trm.pp_diff and expose Trm.pp Reviewed By: ngorogiannis Differential Revision: D24532354 fbshipit-source-id: e51393786 --- sledge/src/trm.ml | 2 ++ sledge/src/trm.mli | 2 ++ 2 files changed, 4 insertions(+) diff --git a/sledge/src/trm.ml b/sledge/src/trm.ml index 92daf7b49..693d035f9 100644 --- a/sledge/src/trm.ml +++ b/sledge/src/trm.ml @@ -390,6 +390,8 @@ type arith = Arith.t include Trm +let pp_diff fs (x, y) = Format.fprintf fs "-- %a ++ %a" pp x pp y + (** Construct *) (* variables *) diff --git a/sledge/src/trm.mli b/sledge/src/trm.mli index 10a8ca329..5fd7dcafe 100644 --- a/sledge/src/trm.mli +++ b/sledge/src/trm.mli @@ -42,6 +42,8 @@ module Arith : Arithmetic.S with type var := Var.t with type trm := t with type t = arith val ppx : Var.strength -> t pp +val pp : t pp +val pp_diff : (t * t) pp (** Construct *)