summaryrefslogtreecommitdiff
path: root/script-beta/core
diff options
context:
space:
mode:
author最萌小汐 <sumneko@hotmail.com>2020-11-17 14:45:49 +0800
committer最萌小汐 <sumneko@hotmail.com>2020-11-17 14:45:49 +0800
commit5a9dd92de2e1caed7cc66c6448a0ee951b47bd4e (patch)
tree93db62825616f73e06ad8540c39493b330e612be /script-beta/core
parent84c8c1500306eae1deccbad02e23c8e8186d452b (diff)
downloadlua-language-server-5a9dd92de2e1caed7cc66c6448a0ee951b47bd4e.zip
还是得把库名与类型名区分开来
Diffstat (limited to 'script-beta/core')
-rw-r--r--script-beta/core/hover/name.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/script-beta/core/hover/name.lua b/script-beta/core/hover/name.lua
index 8394a75b..230de253 100644
--- a/script-beta/core/hover/name.lua
+++ b/script-beta/core/hover/name.lua
@@ -20,6 +20,9 @@ local function asField(source, oop)
local class = vm.getClass(source.node, 'deep')
local node = class or guide.getName(source.node) or '?'
local method = guide.getName(source)
+ if node:sub(-1) == '*' then
+ node = node:sub(1, -2)
+ end
if oop then
return ('%s:%s'):format(node, method)
else