summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--script/core/hint.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/script/core/hint.lua b/script/core/hint.lua
index a2864709..fe86c2a3 100644
--- a/script/core/hint.lua
+++ b/script/core/hint.lua
@@ -3,6 +3,7 @@ local infer = require 'core.infer'
local vm = require 'vm'
local config = require 'config'
local guide = require 'parser.guide'
+local await = require 'await'
local function typeHint(uri, edits, start, finish)
local ast = files.getState(uri)
@@ -37,6 +38,7 @@ local function typeHint(uri, edits, start, finish)
return
end
end
+ await.delay()
local view = infer.searchAndViewInfers(source)
if view == 'any'
or view == 'nil' then
@@ -111,6 +113,7 @@ local function paramName(uri, edits, start, finish)
if not hasLiteralArgInCall(source) then
return
end
+ await.delay()
local defs = vm.getDefs(source.node)
if not defs then
return