From eb191cf9ee775bb8219027d4ba6651cbd39d24d3 Mon Sep 17 00:00:00 2001 From: Ulf Magnusson Date: Sun, 9 Jun 2019 13:31:48 +0200 Subject: Move macro-related $ later in regexes Bit cleaner-looking. --- kconfiglib.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/kconfiglib.py b/kconfiglib.py index 9195055..cff6959 100644 --- a/kconfiglib.py +++ b/kconfiglib.py @@ -6948,11 +6948,11 @@ def _re_search(regex): # # '$' is included to detect preprocessor variable assignments with macro # expansions in the left-hand side. -_command_match = _re_match(r"\s*([$A-Za-z0-9_-]+)\s*") +_command_match = _re_match(r"\s*([A-Za-z0-9_$-]+)\s*") # An identifier/keyword after the first token. Also eats trailing whitespace. # '$' is included to detect identifiers containing macro expansions. -_id_keyword_match = _re_match(r"([$A-Za-z0-9_/.-]+)\s*") +_id_keyword_match = _re_match(r"([A-Za-z0-9_$/.-]+)\s*") # A fragment in the left-hand side of a preprocessor variable assignment. These # are the portions between macro expansions ($(foo)). Macros are supported in -- cgit v1.2.3