summaryrefslogtreecommitdiff
path: root/server/src
diff options
context:
space:
mode:
Diffstat (limited to 'server/src')
-rw-r--r--server/src/core/completion.lua3
-rw-r--r--server/src/core/signature.lua3
-rw-r--r--server/src/vm/local.lua3
3 files changed, 9 insertions, 0 deletions
diff --git a/server/src/core/completion.lua b/server/src/core/completion.lua
index 5ceb916c..1fd0516f 100644
--- a/server/src/core/completion.lua
+++ b/server/src/core/completion.lua
@@ -373,6 +373,9 @@ local function searchCallArg(vm, source, word, callback, pos)
end)
local call = results[1]
local func, args = call:bindCall()
+ if not func then
+ return
+ end
local lib = func:getLib()
if not lib then
diff --git a/server/src/core/signature.lua b/server/src/core/signature.lua
index cafe2799..3e551e38 100644
--- a/server/src/core/signature.lua
+++ b/server/src/core/signature.lua
@@ -48,6 +48,9 @@ end
local function getHover(call, pos)
local func, args = call:bindCall()
+ if not func then
+ return
+ end
local select = getSelect(args, pos)
local source = getFunctionSource(call)
local object = source:get 'object'
diff --git a/server/src/vm/local.lua b/server/src/vm/local.lua
index 6ddaac03..8f9ee3e4 100644
--- a/server/src/vm/local.lua
+++ b/server/src/vm/local.lua
@@ -109,6 +109,9 @@ end
function mt:shadow(old)
if not old then
+ if not self._shadow then
+ return nil
+ end
for i = #self._shadow, 1, -1 do
local loc = self._shadow[i]
if not loc:getSource() then