Semicolon Cleanup

1. Semicolons were required in the wrong spot.
2. Make semicolons "invisible" (from the tree-sitter perspective).

Signed-off-by: Will Hawkins <hawkinsw@obs.cr>
This commit is contained in:
Will Hawkins
2026-02-27 08:23:27 -05:00
parent 1495074459
commit cfe78a9b29
13 changed files with 73 additions and 92 deletions
+2 -1
View File
@@ -32,7 +32,7 @@ extension BlockStatement: ParseableStatement {
let block_statement_query = try? SwiftTreeSitter.Query(
language: p4lang,
data: String(
"(statement . (blockStatement . (statements . ((statement) @astatement (semicolon))*) @statements) @block-statement) @statement"
"(statement . (blockStatement . (statements . ((statement) @astatement)*) @statements) @block-statement) @statement"
).data(using: String.Encoding.utf8)!)
else {
return Result.Ok((.none, scopes))
@@ -55,6 +55,7 @@ extension BlockStatement: ParseableStatement {
let statement_node = statement_capture[0].node
let blockstatement_capture_node = blockstatement_capture[0].node
let statements_capture_node = statements_capture[0].node
/*
if statement_node.parent != node.parent
{