From 4a7dfef8c87e4721b881f652dc6af6c3e2e004ec Mon Sep 17 00:00:00 2001 From: Florian Loitsch Date: Wed, 9 Aug 2023 13:50:19 +0200 Subject: [PATCH] Fix constant syntax highlighting. (#222) --- vscode/syntaxes/toit.tmLanguage.json | 2 +- vscode/syntaxes/toit.tmLanguage.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/vscode/syntaxes/toit.tmLanguage.json b/vscode/syntaxes/toit.tmLanguage.json index f0ab49b..06ae74e 100644 --- a/vscode/syntaxes/toit.tmLanguage.json +++ b/vscode/syntaxes/toit.tmLanguage.json @@ -548,7 +548,7 @@ }, { "name": "constant.numeric.capitalized_user_constants.toit", - "match": "\\b[A-Z][A-Z0-9_]+\\b" + "match": "\\b_*[A-Z](-?[A-Z0-9_])+\\b" } ] }, diff --git a/vscode/syntaxes/toit.tmLanguage.yaml b/vscode/syntaxes/toit.tmLanguage.yaml index 35e3699..183c087 100644 --- a/vscode/syntaxes/toit.tmLanguage.yaml +++ b/vscode/syntaxes/toit.tmLanguage.yaml @@ -335,7 +335,7 @@ repository: - name: constant.language.toit match: \b(null|true|false)\b - name: constant.numeric.capitalized_user_constants.toit - match: \b[A-Z][A-Z0-9_]+\b + match: \b_*[A-Z](-?[A-Z0-9_])+\b number: name: constant.numeric.toit