summaryrefslogtreecommitdiff
path: root/types.c
diff options
context:
space:
mode:
Diffstat (limited to 'types.c')
-rw-r--r--types.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/types.c b/types.c
index e111148..056b800 100644
--- a/types.c
+++ b/types.c
@@ -412,7 +412,7 @@ static Status expr_must_lval(Expression *e, char const *purpose) {
return of_type->kind == TYPE_SLICE
|| (of_type->kind == TYPE_PTR
- && of_type->kind == TYPE_SLICE);
+ && of_type->ptr->kind == TYPE_SLICE);
}
err_print(e->where, "Cannot %s operator %s.", purpose, unary_op_to_str(e->unary.op));
return false;