summaryrefslogtreecommitdiff
path: root/val.c
diff options
context:
space:
mode:
authorubq323 <ubq323@ubq323.website>2024-08-03 17:49:54 +0100
committerubq323 <ubq323@ubq323.website>2024-08-03 17:49:54 +0100
commit1f257ac91ef3813c563203eacb5320b210fc1aa7 (patch)
treeafd68b70c3c5486b7931419f7164c6ddb16023ab /val.c
parentaa0485fe33204169724d020f9c5e3b91e558ab1e (diff)
change array representation
Diffstat (limited to 'val.c')
-rw-r--r--val.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/val.c b/val.c
index 6562daa..685c504 100644
--- a/val.c
+++ b/val.c
@@ -113,10 +113,10 @@ static void print_val_h(Val v, int depth) {
if (depth <= 0)
printf("<arr>");
else {
- printf("[ ");
- for (int i = 0; i < a->len; i++) {
+ printf("[");
+ for (int i = 0; i < a->len ; i++) {
print_val_h(a->d[i], depth-1);
- printf(" ");
+ if (i < a->len - 1) printf(" ");
}
printf("]");
}