From 4989252ed518cc596f4f590bc5d43ae471ff1a39 Mon Sep 17 00:00:00 2001 From: bion howard Date: Wed, 4 Jun 2025 19:07:24 -0400 Subject: [PATCH] fix duplicate comment removal in parse_metal --- tree_plus_src/parse_file.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/tree_plus_src/parse_file.py b/tree_plus_src/parse_file.py index 44e6e6e..c70ca11 100644 --- a/tree_plus_src/parse_file.py +++ b/tree_plus_src/parse_file.py @@ -289,8 +289,6 @@ def parse_metal(content: str, *, timeout: float = DEFAULT_REGEX_TIMEOUT) -> List # Remove comments first content = remove_c_comments(content, timeout=timeout) - content = remove_c_comments(content, timeout=timeout) - # Attributes: [[...]] # Correctly handles nested brackets within attributes if any, and non-greedy matching. attribute_regex_str = r"(?:\[\[(?:[^\[\]]|\[[^\[\]]*\])*\]\]\s*)*"