summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--changelog.md1
-rw-r--r--script/core/noder.lua8
-rw-r--r--test/references/common.lua24
3 files changed, 8 insertions, 25 deletions
diff --git a/changelog.md b/changelog.md
index df0a8350..ec34f4e0 100644
--- a/changelog.md
+++ b/changelog.md
@@ -23,6 +23,7 @@
* `FIX` runtime errors
* `FIX` hint: may show param-2 as `self`
* `FIX` semantic: may fail when scrolling
+* `FIX` [#647](https://github.com/sumneko/lua-language-server/issues/647)
* `FIX` [#660](https://github.com/sumneko/lua-language-server/issues/660)
* `FIX` [#673](https://github.com/sumneko/lua-language-server/issues/673)
diff --git a/script/core/noder.lua b/script/core/noder.lua
index f364f458..d1388cb3 100644
--- a/script/core/noder.lua
+++ b/script/core/noder.lua
@@ -883,8 +883,8 @@ compileNodeMap = util.switch()
: call(function (noders, id, source)
if source.bindSources then
for _, src in ipairs(source.bindSources) do
- pushForward(noders, getID(src), id, INFO_REJECT_SET)
- pushForward(noders, id, getID(src))
+ pushForward(noders, getID(src), id)
+ pushBackward(noders, id, getID(src))
end
end
for _, enumUnit in ipairs(source.enums) do
@@ -898,7 +898,7 @@ compileNodeMap = util.switch()
pushForward(noders, id, unitID)
if source.bindSources then
for _, src in ipairs(source.bindSources) do
- pushBackward(noders, unitID, getID(src), INFO_REJECT_SET)
+ pushBackward(noders, unitID, getID(src))
end
end
end
@@ -972,7 +972,7 @@ compileNodeMap = util.switch()
if source.bindSources then
for _, src in ipairs(source.bindSources) do
pushForward(noders, getID(src), id)
- pushForward(noders, id, getID(src), INFO_REJECT_SET)
+ pushForward(noders, id, getID(src))
end
end
for _, field in ipairs(source.fields) do
diff --git a/test/references/common.lua b/test/references/common.lua
index 3669486b..4245a79d 100644
--- a/test/references/common.lua
+++ b/test/references/common.lua
@@ -221,30 +221,12 @@ TEST [[
---@class A
local a
-a.<!xxx!> = 1
-
---@type A
local b
-b.xxx = 1 -- Dont search this
-
----@class C: A
-local c
-print(c.<?xxx?>)
-]]
-
-TEST [[
----@class A
-local <?a?>
-
----@class B
-local b
-
-b.xx = 1 -- Dont search this
-
----@type B
+---@type A
local c
----@type A
-c.<!xx!> = 1
+b.<?x?> = 1
+c.<!x!> = 1
]]