aboutsummaryrefslogtreecommitdiff
path: root/bootstrap/cgen.c
diff options
context:
space:
mode:
Diffstat (limited to 'bootstrap/cgen.c')
-rw-r--r--bootstrap/cgen.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/bootstrap/cgen.c b/bootstrap/cgen.c
index 0887ca7..d7b91b0 100644
--- a/bootstrap/cgen.c
+++ b/bootstrap/cgen.c
@@ -758,7 +758,9 @@ defctype(const struct type *ty, void *_) {
return;
}
defctype(ty->child, NULL);
+ if (ty->_cname) break;
*cname = xasprintf("__ty%d", id++);
+
pri("typedef struct { %t *ptr; size_t len; } %s;\n",
ty->child, *cname);
pri("_Static_assert(sizeof(%s) == %U, \"sizeof(%t) == %U\");\n",