summaryrefslogtreecommitdiff
path: root/test/definition
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2018-11-20 12:09:06 +0800
committer最萌小汐 <sumneko@hotmail.com>2018-11-20 12:09:06 +0800
commitafea7d6f14e7534a71591447ccc5b1110836ed8c (patch)
tree65c06a356922fb8f25f7bd92cad5e04483b71b69 /test/definition
parent2f75dac6aba312260abb74afce64b1527d2ecea0 (diff)
downloadlua-language-server-afea7d6f14e7534a71591447ccc5b1110836ed8c.zip
支持转到实现
Diffstat (limited to 'test/definition')
-rw-r--r--test/definition/set.lua26
1 files changed, 26 insertions, 0 deletions
diff --git a/test/definition/set.lua b/test/definition/set.lua
index 4cbb5926..2e48e490 100644
--- a/test/definition/set.lua
+++ b/test/definition/set.lua
@@ -2,3 +2,29 @@ TEST [[
<!x!> = 1
<?x?> = 1
]]
+
+TEST [[
+do
+ <!global!> = 1
+end
+<?global?> = 1
+]]
+
+TEST [[
+<!x!> = 1
+do
+ local x = 1
+end
+<?x?> = 1
+]]
+
+TEST [[
+x = 1
+do
+ local <!x!> = 1
+ do
+ x = 2
+ end
+ <?x?> = 1
+end
+]]