diff options
Diffstat (limited to 'script/core/diagnostics/trailing-space.lua')
-rw-r--r-- | script/core/diagnostics/trailing-space.lua | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/script/core/diagnostics/trailing-space.lua b/script/core/diagnostics/trailing-space.lua index aad0b53d..2e0398b2 100644 --- a/script/core/diagnostics/trailing-space.lua +++ b/script/core/diagnostics/trailing-space.lua @@ -1,7 +1,9 @@ local files = require 'files' local lang = require 'language' local guide = require 'parser.guide' +local await = require 'await' +---@async return function (uri, callback) local state = files.getState(uri) local text = files.getText(uri) @@ -10,6 +12,7 @@ return function (uri, callback) end local lines = state.lines for i = 0, #lines do + await.delay() local startOffset = lines[i] local finishOffset = text:find('[\r\n]', startOffset) or (#text + 1) local lastOffset = finishOffset - 1 |