#each parser fix

pull/679/head
Zef Hemel 2024-02-03 15:53:17 +01:00
parent 82cb0ed267
commit dae2111d90
1 changed files with 1 additions and 1 deletions

View File

@ -76,7 +76,7 @@ function processTree(tree: AST): AST {
switch (blockType) {
case "each": {
const eachExpr = blockTextContent.trim();
const eachVarMatch = eachExpr.match(/@(\w+)\s*in\s*(.+)$/s);
const eachVarMatch = eachExpr.match(/^@(\w+)\s*in\s*(.+)$/s);
if (!eachVarMatch) {
// Not a each var declaration, just an expression
const expressionTree = parseTreeToAST(parse(