diff options
author | Leo Tenenbaum <pommicket@gmail.com> | 2020-02-26 18:39:29 -0500 |
---|---|---|
committer | Leo Tenenbaum <pommicket@gmail.com> | 2020-02-26 18:39:29 -0500 |
commit | 03b405750adff0e156f344fd4ab02dd5c6bc4da0 (patch) | |
tree | f798a1c6fc191a427369cf4f8dd2ed4076c257de /types.c | |
parent | e9aab51e78493adb3ccd99ff671d6bac5d16d10c (diff) |
moved errors from cgen to types.c
Diffstat (limited to 'types.c')
-rw-r--r-- | types.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -2783,6 +2783,10 @@ static Status types_decl(Typer *tr, Declaration *d) { success = false; goto ret; } + } else if (d->type.kind == TYPE_UNKNOWN) { + err_print(d->where, "Can't determine type of declaration."); + success = false; + goto ret; } if (d->flags & DECL_IS_CONST) { if (d->type.kind == TYPE_PTR) { |