diff options
author | sumneko <sumneko@hotmail.com> | 2019-04-24 19:22:59 +0800 |
---|---|---|
committer | sumneko <sumneko@hotmail.com> | 2019-04-24 19:22:59 +0800 |
commit | db2de7238fb92269b7ad6aca8a35f82e01eaa126 (patch) | |
tree | 143dbf9e6b5f28db1c20585b36ba959fcaf890b0 /server/src/parser/ast.lua | |
parent | aea74ee33de825921500c3210a65a10ef3c8a8e0 (diff) | |
download | lua-language-server-db2de7238fb92269b7ad6aca8a35f82e01eaa126.zip |
emmy.alias
Diffstat (limited to 'server/src/parser/ast.lua')
-rw-r--r-- | server/src/parser/ast.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/server/src/parser/ast.lua b/server/src/parser/ast.lua index 19aabb9d..8c703491 100644 --- a/server/src/parser/ast.lua +++ b/server/src/parser/ast.lua @@ -1145,6 +1145,8 @@ local Defs = { for i = #result // 2 + 2, #result do result[i] = nil end + result.start = result[1].start + result.finish = result[#result].finish return result end, EmmyArrayType = function (typeName) @@ -1167,6 +1169,8 @@ local Defs = { EmmyAlias = function (name, emmyName, ...) return { type = 'emmyAlias', + start = name.start, + finish = emmyName.finish, name, emmyName, ... @@ -1528,7 +1532,7 @@ return function (self, lua, mode, version) Label = {{}}, Version = version, } - local suc, res, err = xpcall(self.grammar, debug.traceback, lua, mode, Defs) + local suc, res, err = xpcall(self.grammar, debug.traceback, self, lua, mode, Defs) if not suc then return nil, res end |