From a383f2afd20916298551eb5b022128ce54276662 Mon Sep 17 00:00:00 2001 From: Josh Berdine Date: Wed, 10 Jun 2020 07:05:43 -0700 Subject: [PATCH] [infer] Remove ppx_compare workaround for nonrec types Summary: The past issue with ppx_compare on nonrec types has (at some point) been fixed. Cf. https://github.com/janestreet/ppx_compare/issues/2 Reviewed By: ngorogiannis Differential Revision: D21961645 fbshipit-source-id: de03a60a4 --- infer/src/IR/Annot.ml | 7 +------ infer/src/checkers/SiofTrace.ml | 6 +----- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/infer/src/IR/Annot.ml b/infer/src/IR/Annot.ml index fce165944..e5e51434a 100644 --- a/infer/src/IR/Annot.ml +++ b/infer/src/IR/Annot.ml @@ -85,13 +85,8 @@ and pp fmt annotation = module Item = struct - (* Don't use nonrec due to https://github.com/janestreet/ppx_compare/issues/2 *) - (* type nonrec t = list (t, bool) [@@deriving compare]; *) - (** Annotation for one item: a list of annotations with visibility. *) - type t_ = (t * bool) list [@@deriving compare] - - type t = t_ [@@deriving compare] + type nonrec t = (t * bool) list [@@deriving compare] (** Pretty print an item annotation. *) let pp fmt ann = diff --git a/infer/src/checkers/SiofTrace.ml b/infer/src/checkers/SiofTrace.ml index 4f7e3dbd1..26678bce2 100644 --- a/infer/src/checkers/SiofTrace.ml +++ b/infer/src/checkers/SiofTrace.ml @@ -42,11 +42,7 @@ module TraceElem = struct module Set = PrettyPrintable.MakePPSet (struct - (* Don't use nonrec due to https://github.com/janestreet/ppx_compare/issues/2 *) - (* type nonrec t = t [@@deriving compare]; *) - type nonrec t = t - - let compare = compare + type nonrec t = t [@@deriving compare] let pp = pp end)