[gtksourceview: 3/5] lean.lang: various clean-ups
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview: 3/5] lean.lang: various clean-ups
- Date: Mon, 5 Sep 2022 22:24:53 +0000 (UTC)
commit 61b90d4f5f71cf3681a83548218eef3f691615c9
Author: Elias Aebi <353-eyelash users noreply gitlab gnome org>
Date: Sat Sep 3 11:59:29 2022 +0200
lean.lang: various clean-ups
data/language-specs/lean.lang | 34 ++++++++++++++++------------------
1 file changed, 16 insertions(+), 18 deletions(-)
---
diff --git a/data/language-specs/lean.lang b/data/language-specs/lean.lang
index 7a24beba..c5cb8270 100644
--- a/data/language-specs/lean.lang
+++ b/data/language-specs/lean.lang
@@ -69,7 +69,7 @@
<context id="command" style-ref="command">
<match extended="true">
- \#(
+ \#(?:
check(_failure)?
| eval
| print
@@ -112,24 +112,24 @@
<keyword>λ</keyword>
</context>
- <define-regex id="string-escape" extended="true">
- \\(
- \\
- | \"
- | \'
- | n
- | t
- | x[0-9a-fA-F]{2}
- )
- </define-regex>
+ <context id="escaped-character" style-ref="escaped-character">
+ <match extended="true">
+ \\(?:
+ \\
+ | \"
+ | \'
+ | n
+ | t
+ | x[0-9a-fA-F]{2}
+ )
+ </match>
+ </context>
<context id="string" style-ref="string" end-at-line-end="true" class="string"
class-disabled="no-spell-check">
<start>"</start>
<end>"</end>
<include>
- <context style-ref="escaped-character">
- <match>\%{string-escape}</match>
- </context>
+ <context ref="escaped-character"/>
</include>
</context>
@@ -137,15 +137,13 @@
<start>'</start>
<end>'</end>
<include>
- <context style-ref="escaped-character">
- <match>\%{string-escape}</match>
- </context>
+ <context ref="escaped-character"/>
</include>
</context>
<context id="numeric" style-ref="numeric">
<match extended="true">
- 0[bB][0-1]+
+ 0[bB][01]+
| 0[oO][0-7]+
| 0[xX][0-9a-fA-F]+
| [0-9]+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]