diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-11-15 17:11:57 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-11-15 17:11:57 +0800 |
commit | afc040fa210cfe5c21b4d92c20604a5c24bec4ca (patch) | |
tree | c8f25ccd2e0550cbddd583462e6761e5813e710d | |
parent | eab65efca420889312e226e04867f2ce408dcdb0 (diff) | |
download | lua-language-server-afc040fa210cfe5c21b4d92c20604a5c24bec4ca.zip |
漏了一个
-rw-r--r-- | server-beta/src/core/reference.lua | 1 | ||||
-rw-r--r-- | server-beta/test/references/init.lua | 8 |
2 files changed, 9 insertions, 0 deletions
diff --git a/server-beta/src/core/reference.lua b/server-beta/src/core/reference.lua index 34487d30..1e845630 100644 --- a/server-beta/src/core/reference.lua +++ b/server-beta/src/core/reference.lua @@ -24,6 +24,7 @@ local function findRef(source, offset, callback) and source.type ~= 'number' and source.type ~= 'boolean' and source.type ~= 'goto' + and source.type ~= 'label' and not isFunction(source, offset) then return end diff --git a/server-beta/test/references/init.lua b/server-beta/test/references/init.lua index e009ee19..327f4789 100644 --- a/server-beta/test/references/init.lua +++ b/server-beta/test/references/init.lua @@ -71,6 +71,14 @@ end ]] TEST [[ +:: <?LABEL?> :: +goto <!LABEL!> +if true then + goto <!LABEL!> +end +]] + +TEST [[ local a = 1 local <?a?> = 1 <!a!> = <!a!> |