From: Michael Wallner Date: Thu, 29 Nov 2018 09:01:12 +0000 (+0100) Subject: add test X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=81a4197fb79ce651cb6f8cfe5adbef0422ef1bea;p=m6w6%2Fext-psi add test --- diff --git a/tests/parser/cpp004.phpt b/tests/parser/cpp004.phpt new file mode 100644 index 0000000..2278e23 --- /dev/null +++ b/tests/parser/cpp004.phpt @@ -0,0 +1,23 @@ +--TEST-- +CPP argument prescan +--SKIPIF-- + +--INI-- +psi.directory={PWD}/cpp004 +--FILE-- +===TEST=== + +===DONE=== +--EXPECT-- +===TEST=== +int(0) +int(1) +int(2) +int(3003) +int(4004) +int(5005) +===DONE=== diff --git a/tests/parser/cpp004/builtins.psi b/tests/parser/cpp004/builtins.psi new file mode 100644 index 0000000..d6cbf38 --- /dev/null +++ b/tests/parser/cpp004/builtins.psi @@ -0,0 +1,10 @@ +const \CPP_TEST0 = __COUNTER__; +const \CPP_TEST1 = __COUNTER__; +const \CPP_TEST2 = __COUNTER__; + +#define a(x,y) x ## y +#define b(x,y) a(x,y) +#define c(x) b(x, __COUNTER__) +const \CPP_TEST3 = c(300); +const \CPP_TEST4 = c(400); +const \CPP_TEST5 = c(500);