Fix error reporting for assignment to a built-in procedure (#183)

This commit is contained in:
gingerBill
2018-02-07 18:55:01 +00:00
parent 001b48a5c6
commit 8f913c656c

View File

@@ -203,7 +203,9 @@ Type *check_assignment_variable(Checker *c, Operand *lhs, Operand *rhs) {
bool used = false;
if (lhs->mode == Addressing_Invalid ||
(lhs->type == t_invalid && lhs->mode != Addressing_ProcGroup)) {
(lhs->type == t_invalid &&
lhs->mode != Addressing_ProcGroup &&
lhs->mode != Addressing_Builtin)) {
return nullptr;
}