mirror of
https://github.com/DarkPlacesEngine/gmqcc.git
synced 2025-03-22 18:51:24 +00:00
Typedef testcases
This commit is contained in:
parent
f6a374c1d5
commit
7cd6a477f8
2 changed files with 17 additions and 0 deletions
12
tests/typedefs.qc
Normal file
12
tests/typedefs.qc
Normal file
|
@ -0,0 +1,12 @@
|
|||
typedef void(string, ...) ptype;
|
||||
typedef string(float) funcsf;
|
||||
|
||||
ptype print = #1;
|
||||
funcsf ftos = #2;
|
||||
|
||||
void main() {
|
||||
typedef float funcsf;
|
||||
funcsf a;
|
||||
a = 0;
|
||||
print("A typedeffed function, 0=", ftos(a), "\n");
|
||||
}
|
5
tests/typedefs.tmpl
Normal file
5
tests/typedefs.tmpl
Normal file
|
@ -0,0 +1,5 @@
|
|||
I: typtedefs.qc
|
||||
D: typedefs
|
||||
T: -execute
|
||||
C: -std=fteqcc
|
||||
M: A typedeffed function, 0=0
|
Loading…
Reference in a new issue