diff options
Diffstat (limited to 'test-beta/definition/set.lua')
-rw-r--r-- | test-beta/definition/set.lua | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/test-beta/definition/set.lua b/test-beta/definition/set.lua new file mode 100644 index 00000000..f36be078 --- /dev/null +++ b/test-beta/definition/set.lua @@ -0,0 +1,40 @@ +TEST [[ +<!x!> = 1 +<?x?>() +]] + +TEST [[ +do + <!global!> = 1 +end +<?global?>() +]] + +TEST [[ +<!x!> = 1 +do + local x = 1 +end +<?x?>() +]] + +TEST [[ +x = 1 +do + local <!x!> = 1 + do + <!x!> = 2 + end + <?x?>() +end +]] + +TEST [[ +<!x!> = 1 +if y then + <!x!> = 2 +else + <!x!> = 3 +end +print(<?x?>) +]] |