mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-03-20 01:11:18 +00:00
finish the break overloading and add some more tests (really need to get these automated)
This commit is contained in:
parent
5a78bf1bff
commit
25bf40a71a
3 changed files with 19 additions and 1 deletions
|
@ -205,7 +205,7 @@ storage_class_t current_storage = st_global;
|
|||
|
||||
%}
|
||||
|
||||
%expect 4
|
||||
%expect 5
|
||||
|
||||
%%
|
||||
|
||||
|
@ -1070,6 +1070,7 @@ unary_expr
|
|||
|
||||
primary
|
||||
: NAME { $$ = new_name_expr ($1); }
|
||||
| BREAK { $$ = new_name_expr (save_string ("break")); }
|
||||
| ARGS { $$ = new_name_expr (".args"); }
|
||||
| ARGC { $$ = argc_expr (); }
|
||||
| ARGV { $$ = argv_expr (); }
|
||||
|
|
9
tools/qfcc/test/break.r
Normal file
9
tools/qfcc/test/break.r
Normal file
|
@ -0,0 +1,9 @@
|
|||
void () break = #0;
|
||||
|
||||
void () foo =
|
||||
{
|
||||
break ();
|
||||
while (1) {
|
||||
break;
|
||||
}
|
||||
};
|
8
tools/qfcc/test/vector_float.r
Normal file
8
tools/qfcc/test/vector_float.r
Normal file
|
@ -0,0 +1,8 @@
|
|||
vector vec;
|
||||
float f;
|
||||
|
||||
void()foo =
|
||||
{
|
||||
vec = f;
|
||||
f = vec;
|
||||
}
|
Loading…
Reference in a new issue