X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ast2firm.c;h=f92f870d99d20e2a4ceec3b9c4599c02a27d8a21;hb=6b26906854c2f5423fa3986a0caf3c23b200b553;hp=1f9b46791fa3da25814f3d85aed0b847e17454e6;hpb=44b30d66b1236f3eaad9170abc1967527d264fe0;p=cparser diff --git a/ast2firm.c b/ast2firm.c index 1f9b467..f92f870 100644 --- a/ast2firm.c +++ b/ast2firm.c @@ -2524,6 +2524,11 @@ static ir_node *create_cast(dbg_info *dbgi, ir_node *value_node, type_t *from_type, type_t *type) { type = skip_typeref(type); + if (type == type_void) { + /* make sure firm type is constructed */ + (void) get_ir_type(type); + return NULL; + } if (!is_type_scalar(type)) { /* make sure firm type is constructed */ (void) get_ir_type(type);