Best viable overloading procedure algorithm; no_alias; call expr style casts

This commit is contained in:
Ginger Bill
2017-01-17 15:20:11 +00:00
parent 6dc6b6f8aa
commit 383f5b55ad
14 changed files with 366 additions and 222 deletions
+3 -2
View File
@@ -276,8 +276,9 @@ void check_const_decl(Checker *c, Entity *e, AstNode *type_expr, AstNode *init,
check_init_constant(c, e, &operand);
if (operand.mode == Addressing_Invalid) {
error(e->token, "Illegal cyclic declaration");
if (operand.mode == Addressing_Invalid ||
base_type(operand.type) == t_invalid) {
error(e->token, "Invalid declaration type");
}
}