From 8b736c7c72bc450eec8a7acc26bb50740dc5a018 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicol=C3=B2=20Santamaria?= Date: Mon, 23 Oct 2023 16:15:40 +0200 Subject: [PATCH] Bug fix. --- internal/compiler/codec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/internal/compiler/codec.c b/internal/compiler/codec.c index 172e291..bfe7025 100644 --- a/internal/compiler/codec.c +++ b/internal/compiler/codec.c @@ -81,7 +81,7 @@ static inline void encode_objects(struct buffer *buf, struct object *objs, size_ write_uint32(buf, o.data.str->len); write_string(buf, o.data.str->str); break; - case obj_function: + case obj_function: { struct function *fn = o.data.fn; write_uint32(buf, fn->num_params); write_uint32(buf, fn->num_locals); @@ -90,6 +90,7 @@ static inline void encode_objects(struct buffer *buf, struct object *objs, size_ write_uint32(buf, fn->bklen); encode_bookmarks(buf, fn->bookmarks, fn->bklen); break; + } default: fatalf("encoder: unsupported encoding for type %s\n", otype_str(o.type)); }