diff --git a/grammar.js b/grammar.js index 13334e1..52271f5 100644 --- a/grammar.js +++ b/grammar.js @@ -29,10 +29,10 @@ module.exports = grammar({ function_definition: $ => choice($.func, $.block), func: $ => seq( 'func', $._spacing, - $.identifier, $._spacing, choice(seq('@', $.identifier, $.block), $.block), + $.identifier, $._spacing, choice(seq('@', $.identifier, '{', $._spacing, repeat(/./), $._spacing, '}'), $.block), ), block: $ => seq( - optional('!'), '{', optional($._spacing, repeat(seq(/[^ \n\r\t|]+/, $._spacing)), '|'), + '{', $._spacing, repeat(seq(/[^ \n\r\t|]+/, $._spacing), '|'), repeat($._statement), '}', ),