From f77c9eb757f25175afcd91f772bed38df629ee02 Mon Sep 17 00:00:00 2001 From: "Allen S. Rout" Date: Fri, 14 Apr 2023 13:59:52 -0400 Subject: [PATCH] Make provision for block on next line. --- hcl2/hcl2.lark | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hcl2/hcl2.lark b/hcl2/hcl2.lark index 86639b06..08b1d513 100644 --- a/hcl2/hcl2.lark +++ b/hcl2/hcl2.lark @@ -1,7 +1,7 @@ start : body body : (new_line_or_comment? (attribute | block))* new_line_or_comment? attribute : identifier "=" expression -block : identifier (identifier | STRING_LIT)* "{" body "}" +block : identifier (identifier | STRING_LIT)* new_line_or_comment? "{" body "}" new_line_and_or_comma: new_line_or_comment | "," | "," new_line_or_comment new_line_or_comment: ( /\n/ | /#.*\n/ | /\/\/.*\n/ )+