mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 07:11:41 +00:00
Treat class instance access as a normal error.
Normally, it will happen only as a follow-on error, but I can think of a way to force it without other errors, so treating it as an internal error is a bit harsh.
This commit is contained in:
parent
996b2734a4
commit
aae0e21a5b
1 changed files with 3 additions and 1 deletions
|
@ -1040,7 +1040,9 @@ field_expr (expr_t *e1, expr_t *e2)
|
|||
return unary_expr ('.', e);
|
||||
}
|
||||
} else if (obj_is_class (t1)) {
|
||||
internal_error (e1, "access to class instances not implemented");
|
||||
//Class instance variables aren't allowed and thus declaring one
|
||||
//is treated as an error, so this is a follow-on error.
|
||||
return error (e1, "class instance access");
|
||||
}
|
||||
return type_mismatch (e1, e2, '.');
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue