aboutsummaryrefslogtreecommitdiff
path: root/bootstrap/cgen.c
diff options
context:
space:
mode:
authorlemon <lsof@mailbox.org>2022-08-30 10:41:16 +0200
committerlemon <lsof@mailbox.org>2022-08-30 10:41:16 +0200
commitdea68bafe81c40adf29e45630cfeceb97b91a630 (patch)
tree687c50f8e1402ed30ee711d27647aad8251a015c /bootstrap/cgen.c
parente4163c18cdc3522f24e459cd6ddde60edb1605e2 (diff)
Makefile and such
Diffstat (limited to 'bootstrap/cgen.c')
-rw-r--r--bootstrap/cgen.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/bootstrap/cgen.c b/bootstrap/cgen.c
index 0bd7851..7db84ea 100644
--- a/bootstrap/cgen.c
+++ b/bootstrap/cgen.c
@@ -815,6 +815,9 @@ defctype(const struct type *ty, void *_) {
}
break;
case TYslice:
+ if (ty->konst) {
+ ty = unconstify(ty);
+ }
if (ty->child->konst) {
const struct type *ty2 = unconstifychild(ty);
defctype(ty2, NULL);