From b1990ceb2622c18f99c75b980dfd4ca8a0f0ed6c Mon Sep 17 00:00:00 2001 From: "Jan T. Sott" Date: Fri, 3 Dec 2021 18:51:42 +0100 Subject: [PATCH] enh(nsis) Update defines pattern to allow `!` (#3417) Defines can include `!`-characters, as seen in this example: https://nsis.sourceforge.io/Check_if_a_file_exists_at_compile_time --- CHANGES.md | 3 ++- src/languages/nsis.js | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index a0b1160598..7d6636393f 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -7,6 +7,7 @@ Grammars: - enh(swift) add SE-0290 unavailability condition (#3382) [Bradley Mackey][] - fix(fsharp) Highlight operators, match type names only in type annotations, support quoted identifiers, and other smaller fixes. [Melvyn Laïly][] - enh(java) add `sealed` and `non-sealed` keywords (#3386) [Bradley Mackey][] +- enh(nsis) Update defines pattern to allow `!` (#3417) [idleberg][] - fix(clojure) Several issues with Clojure highlighting (#3397) [Björn Ebbinghaus][] - fix(clojure) `comment` macro catches more than it should (#3395) - fix(clojure) `$` in symbol breaks highlighting @@ -31,7 +32,7 @@ Themes: [Björn Ebbinghaus]: https://github.com/MrEbbinghaus [Josh Goebel]: https://github.com/joshgoebel [Samia Ali]: https://github.com/samiaab1990 - +[idleberg]: https://github.com/idleberg ## Version 11.3.1 diff --git a/src/languages/nsis.js b/src/languages/nsis.js index fa3b2e547f..fd64106d27 100644 --- a/src/languages/nsis.js +++ b/src/languages/nsis.js @@ -153,7 +153,7 @@ export default function(hljs) { const DEFINES = { // ${defines} className: 'variable', - begin: /\$+\{[\w.:-]+\}/ + begin: /\$+\{[\!\w.:-]+\}/ }; const VARIABLES = {