diff options
Diffstat (limited to 'script/core/diagnostics/newfield-call.lua')
-rw-r--r-- | script/core/diagnostics/newfield-call.lua | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/script/core/diagnostics/newfield-call.lua b/script/core/diagnostics/newfield-call.lua index a71ae3e1..75681cbc 100644 --- a/script/core/diagnostics/newfield-call.lua +++ b/script/core/diagnostics/newfield-call.lua @@ -1,5 +1,5 @@ local files = require 'files' -local searcher = require 'core.searcher' +local guide = require 'parser.guide' local lang = require 'language' return function (uri, callback) @@ -11,15 +11,15 @@ return function (uri, callback) local lines = files.getLines(uri) local text = files.getText(uri) - searcher.eachSourceType(ast.ast, 'table', function (source) + guide.eachSourceType(ast.ast, 'table', function (source) for i = 1, #source do local field = source[i] if field.type == 'call' then local func = field.node local args = field.args if args then - local funcLine = searcher.positionOf(lines, func.finish) - local argsLine = searcher.positionOf(lines, args.start) + local funcLine = guide.positionOf(lines, func.finish) + local argsLine = guide.positionOf(lines, args.start) if argsLine > funcLine then callback { start = field.start, |