summaryrefslogtreecommitdiff
path: root/tolua/src/tests/tdirective.pkg
diff options
context:
space:
mode:
Diffstat (limited to 'tolua/src/tests/tdirective.pkg')
-rw-r--r--tolua/src/tests/tdirective.pkg28
1 files changed, 28 insertions, 0 deletions
diff --git a/tolua/src/tests/tdirective.pkg b/tolua/src/tests/tdirective.pkg
new file mode 100644
index 0000000..024c795
--- /dev/null
+++ b/tolua/src/tests/tdirective.pkg
@@ -0,0 +1,28 @@
+$#include "lualib.h"
+$#include "lauxlib.h"
+
+$int a;
+$extern int a;
+
+$int main (void)
+${
+$ lua_State* L = luaL_newstate();
+$ luaopen_base(L);
+$ tolua_tdirective_open(L);
+$ luaL_dofile(L,"tdirective.lua");
+$ lua_close(L);
+$ return 0;
+$}
+
+$pfile "tdirectivepkg.pkg"
+
+$<
+ a = 3;
+$>
+
+$[
+A = 4
+$]
+
+$lfile "tdirectivelua.lua"
+