From c8f3bb4f04a010f7b7c3d855c5363e87f82550b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Suzanne=20Dup=C3=A9ron?= Date: Mon, 27 Apr 2020 13:01:09 +0100 Subject: [PATCH] improve printer: Var name --- src/stages/4-ast_typed/PP_generic.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stages/4-ast_typed/PP_generic.ml b/src/stages/4-ast_typed/PP_generic.ml index fc9bbeb9d..d807689e0 100644 --- a/src/stages/4-ast_typed/PP_generic.ml +++ b/src/stages/4-ast_typed/PP_generic.ml @@ -10,7 +10,7 @@ let needs_parens = { | PolyInstance { poly =_; arguments=_; poly_continue } -> (poly_continue state) ); - type_variable = (fun _ _ _ -> false) ; + type_variable = (fun _ _ _ -> true) ; bool = (fun _ _ _ -> false) ; z = (fun _ _ _ -> false) ; string = (fun _ _ _ -> false) ; @@ -48,7 +48,7 @@ let op ppf = { | PolyInstance { poly=_; arguments=_; poly_continue } -> (poly_continue ()) ); - type_variable = (fun _visitor () type_variable -> fprintf ppf "%a" Var.pp type_variable) ; + type_variable = (fun _visitor () type_variable -> fprintf ppf "Var %a" Var.pp type_variable) ; bool = (fun _visitor () b -> fprintf ppf "%s" (if b then "true" else "false")) ; z = (fun _visitor () i -> fprintf ppf "%a" Z.pp_print i) ; string = (fun _visitor () str -> fprintf ppf "\"%s\"" str) ;