mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-29 23:52:22 +00:00
[qfcc] Check returned type instead of expr type
Block expressions hide ex_error, but get_type() always returns null when it finds one (which it does by recursing into block expression), so just check the type itself.
This commit is contained in:
parent
5b842da394
commit
0426879bf6
1 changed files with 1 additions and 1 deletions
|
@ -2075,7 +2075,7 @@ return_expr (function_t *f, expr_t *e)
|
||||||
|
|
||||||
t = get_type (e);
|
t = get_type (e);
|
||||||
|
|
||||||
if (e->type == ex_error) {
|
if (!t) {
|
||||||
return e;
|
return e;
|
||||||
}
|
}
|
||||||
if (is_void(ret_type)) {
|
if (is_void(ret_type)) {
|
||||||
|
|
Loading…
Reference in a new issue