From: Wolfgang (Blub) Bumiller Date: Sun, 25 Nov 2012 14:33:03 +0000 (+0100) Subject: Typedef testcases X-Git-Tag: 0.1.9~272 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=7cd6a477f8fae39b56775eebbaa134c69615c0ab;p=xonotic%2Fgmqcc.git Typedef testcases --- diff --git a/tests/typedefs.qc b/tests/typedefs.qc new file mode 100644 index 0000000..79143fd --- /dev/null +++ b/tests/typedefs.qc @@ -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"); +} diff --git a/tests/typedefs.tmpl b/tests/typedefs.tmpl new file mode 100644 index 0000000..4aa8ee2 --- /dev/null +++ b/tests/typedefs.tmpl @@ -0,0 +1,5 @@ +I: typtedefs.qc +D: typedefs +T: -execute +C: -std=fteqcc +M: A typedeffed function, 0=0