From c9b0b9e64f8d4744ac8bb8a80f9f397318c51ba4 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sun, 11 Dec 2022 03:40:17 +0100 Subject: [PATCH] add quotes --- test.ml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test.ml b/test.ml index 9e8c1c2..da94735 100644 --- a/test.ml +++ b/test.ml @@ -8,7 +8,7 @@ let debug_parser oc parsed = | Syntax.Void -> "Void" | Syntax.Int d -> "Int " ^ string_of_int d | Syntax.Bool d -> "Bool " ^ string_of_bool d - | Syntax.Str s -> "Str " ^ s + | Syntax.Str s -> "Str \"" ^ s ^ "\"" and fmt_e = function | Syntax.Val d -> "Val (" ^ fmt_v d.value ^ ")" | Syntax.Var d -> "Var \"" ^ d.name ^ "\"" @@ -46,7 +46,7 @@ let debug_semantics oc ast = | Void -> "Void" | Int n -> "Int " ^ string_of_int n | Bool b -> "Bool " ^ string_of_bool b - | Str s -> "String " ^ s + | Str s -> "Str \"" ^ s ^ "\"" and fmt_e = function | Val v -> "Val (" ^ fmt_v v ^ ")" | Var v -> "Var \"" ^ v ^ "\""