From 6fda59fd5e57e9267d2ec0480d53b5f9b0546855 Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 6 Apr 2025 16:22:21 -0400 Subject: Fixes for printing sets and tables --- src/stdlib/tables.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/stdlib/tables.c b/src/stdlib/tables.c index 58c1b2e4..71b9c7f4 100644 --- a/src/stdlib/tables.c +++ b/src/stdlib/tables.c @@ -583,7 +583,7 @@ public Text_t Table$as_text(const void *obj, bool colorize, const TypeInfo_t *ty return Text$concat( Text("{"), generic_as_text(NULL, false, table.key), - Text(","), + Text("="), generic_as_text(NULL, false, table.value), Text("}")); else @@ -604,6 +604,9 @@ public Text_t Table$as_text(const void *obj, bool colorize, const TypeInfo_t *ty text = Text$concat(text, Text("="), generic_as_text(entry + val_off, colorize, table.value)); } + if (table.value == &Void$info) + text = Text$concat(text, Text("/")); + if (t->fallback) { text = Text$concat(text, Text("; fallback="), Table$as_text(t->fallback, colorize, type)); } -- cgit v1.2.3