aboutsummaryrefslogtreecommitdiff
path: root/scripts/luacats_grammar.lua
diff options
context:
space:
mode:
authorLewis Russell <lewis6991@gmail.com>2024-03-05 12:06:15 +0000
committerLewis Russell <me@lewisr.dev>2024-03-05 13:36:46 +0000
commita4290f462ed7dc81e17b09bd27877b106b24b6bd (patch)
treeab880e80f92fe337ff4581eba2454bb4b882375a /scripts/luacats_grammar.lua
parent5b312cd5f67646005312d2ebb2ef0d1bc584dcff (diff)
downloadrneovim-a4290f462ed7dc81e17b09bd27877b106b24b6bd.tar.gz
rneovim-a4290f462ed7dc81e17b09bd27877b106b24b6bd.tar.bz2
rneovim-a4290f462ed7dc81e17b09bd27877b106b24b6bd.zip
docs(lua): improvements for LSP and Diagnostic
Diffstat (limited to 'scripts/luacats_grammar.lua')
-rw-r--r--scripts/luacats_grammar.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/scripts/luacats_grammar.lua b/scripts/luacats_grammar.lua
index 0beb1d2352..158541dc77 100644
--- a/scripts/luacats_grammar.lua
+++ b/scripts/luacats_grammar.lua
@@ -170,7 +170,7 @@ local grammar = P {
ltype = parenOpt(v.ty_union),
ty_union = v.ty_opt * rep(Pf('|') * v.ty_opt),
- ty = v.ty_fun + ident + v.ty_table + literal,
+ ty = v.ty_fun + ident + v.ty_table + literal + paren(v.ty),
ty_param = Pf('<') * comma1(v.ltype) * fill * P('>'),
ty_opt = v.ty * opt(v.ty_param) * opt(P('[]')) * opt(P('?')),
ty_index = (Pf('[') * v.ltype * Pf(']')),