diff options
-rw-r--r-- | Changes | 1 | ||||
-rw-r--r-- | parsing/pprintast.ml | 8 |
2 files changed, 5 insertions, 4 deletions
@@ -26,6 +26,7 @@ Compilers: - improve type-specialization of unapplied primitives (Frédéric Bour, review by Gabriel Scherer) - PR#6737: fix Typedtree attributes on (fun x -> body) expressions +- PR#6679: fix pprintast printing of constraints in type declarations Runtime system: - PR#6517: use ISO C99 types {,u}int{32,64}_t in preference to our homegrown diff --git a/parsing/pprintast.ml b/parsing/pprintast.ml index 6d1d22c14..c72e09941 100644 --- a/parsing/pprintast.ml +++ b/parsing/pprintast.ml @@ -1289,11 +1289,11 @@ class printer ()= object(self:'self) | Ptype_open -> pp f "%t@;.." intro in let constraints f = - self#list ~first:"@ " - (fun f (ct1,ct2,_) -> - pp f "@[<hov2>constraint@ %a@ =@ %a@]" + List.iter + (fun (ct1,ct2,_) -> + pp f "@[<hov2>@ constraint@ %a@ =@ %a@]" self#core_type ct1 self#core_type ct2) - f x.ptype_cstrs + x.ptype_cstrs in pp f "%t%t%t%t" priv manifest repr constraints |