mirror of
https://github.com/Ed94/Odin.git
synced 2026-08-06 15:48:51 +00:00
Fix #3573
This commit is contained in:
@@ -1794,6 +1794,13 @@ gb_internal bool check_unary_op(CheckerContext *c, Operand *o, Token op) {
|
|||||||
gb_string_free(str);
|
gb_string_free(str);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
if (o->mode == Addressing_Type) {
|
||||||
|
gbString str = type_to_string(o->type);
|
||||||
|
error(o->expr, "Expected an expression for operator '%.*s', got type '%s'", LIT(op.string), str);
|
||||||
|
gb_string_free(str);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
Type *type = base_type(core_array_type(o->type));
|
Type *type = base_type(core_array_type(o->type));
|
||||||
gbString str = nullptr;
|
gbString str = nullptr;
|
||||||
switch (op.kind) {
|
switch (op.kind) {
|
||||||
|
|||||||
Reference in New Issue
Block a user