diff options
author | 最萌小汐 <sumneko@hotmail.com> | 2019-02-06 12:10:18 +0800 |
---|---|---|
committer | 最萌小汐 <sumneko@hotmail.com> | 2019-02-06 12:10:18 +0800 |
commit | b8c82d086c73a3fc18290a3cac31d4fd9bede6e8 (patch) | |
tree | 1bf24a1e178c5c1ad20c52d3ff147f57fca40ab1 /server/src/parser/grammar.lua | |
parent | ae5c35babefe1eca7a3c85db68ffb74ffc18abf1 (diff) | |
download | lua-language-server-b8c82d086c73a3fc18290a3cac31d4fd9bede6e8.zip |
fix #6
Diffstat (limited to 'server/src/parser/grammar.lua')
-rw-r--r-- | server/src/parser/grammar.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/parser/grammar.lua b/server/src/parser/grammar.lua index 17ac4faf..7066a9e6 100644 --- a/server/src/parser/grammar.lua +++ b/server/src/parser/grammar.lua @@ -198,7 +198,7 @@ UnaryOp <- {} {'not' Cut / '#' / '~' / '-'} PL <- Sp '(' PR <- Sp ')' -BL <- Sp '[' +BL <- Sp '[' !'[' !'=' BR <- Sp ']' TL <- Sp '{' TR <- Sp '}' @@ -339,7 +339,7 @@ Table <- Sp ({} TL TableFields? DirtyTR) TableFields <- (TableSep {} / TableField)+ TableSep <- COMMA / SEMICOLON TableField <- NewIndex / NewField / Exp -NewIndex <- Sp ({} BL !BL !ASSIGN DirtyExp DirtyBR NeedAssign DirtyExp) +NewIndex <- Sp ({} BL DirtyExp DirtyBR NeedAssign DirtyExp) -> NewIndex NewField <- (MustName ASSIGN DirtyExp) -> NewField |