[gtksourceview: 1/3] cpp.lang: highlight nullptr as a special constant
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtksourceview: 1/3] cpp.lang: highlight nullptr as a special constant
- Date: Mon, 10 Jan 2022 20:02:10 +0000 (UTC)
commit 60c75f9d2ea17069518fca0a7730d2f4e06fa2c1
Author: Elias Aebi <353-eyelash users noreply gitlab gnome org>
Date: Mon Jan 10 19:39:04 2022 +0100
cpp.lang: highlight nullptr as a special constant
data/language-specs/cpp.lang | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
---
diff --git a/data/language-specs/cpp.lang b/data/language-specs/cpp.lang
index 8f350c10..bc20eba6 100644
--- a/data/language-specs/cpp.lang
+++ b/data/language-specs/cpp.lang
@@ -35,6 +35,7 @@
<style id="raw-string" name="Raw String" map-to="def:string"/>
<style id="keyword" name="Keyword" map-to="c:keyword"/>
<style id="type" name="Data Type" map-to="c:type"/>
+ <style id="nullptr" name="Null Pointer Value" map-to="def:special-constant"/>
<style id="common-defines" name="Common Defines" map-to="c:common-defines"/>
</styles>
@@ -73,7 +74,6 @@
<keyword>noexcept</keyword>
<keyword>not</keyword>
<keyword>not_eq</keyword>
- <keyword>nullptr</keyword>
<keyword>operator</keyword>
<keyword>or</keyword>
<keyword>or_eq</keyword>
@@ -107,6 +107,10 @@
<keyword>nullptr_t</keyword>
</context>
+ <context id="nullptr" style-ref="nullptr">
+ <keyword>nullptr</keyword>
+ </context>
+
<context id="common-defines" style-ref="common-defines">
<keyword>__STDC__</keyword>
<keyword>__cplusplus</keyword>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]