summaryrefslogtreecommitdiff
path: root/src/parser/grammar.lua
diff options
context:
space:
mode:
Diffstat (limited to 'src/parser/grammar.lua')
-rw-r--r--src/parser/grammar.lua9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/parser/grammar.lua b/src/parser/grammar.lua
index a4240df2..cb2d2e6f 100644
--- a/src/parser/grammar.lua
+++ b/src/parser/grammar.lua
@@ -233,13 +233,10 @@ TableField <- NewIndex / NewField / Exp
NewIndex <- BL Exp BR ASSIGN Exp
NewField <- Name ASSIGN Exp
-Function <- {|
- FUNCTION FuncName? PL ArgList? PR
- (!END Action)*
+Function <- (FUNCTION {| FuncName? |} PL ArgList? PR) -> FunctionDef
+ (!END Action)* -> Function
END
- |}
- -> Function
-FuncName <- {:name: {| Name (FuncSuffix)* |} :}
+FuncName <- Name (FuncSuffix)*
FuncSuffix <- DOT Name
/ COLON Name