summaryrefslogtreecommitdiff
path: root/pygments
diff options
context:
space:
mode:
authorbitsawer <sawerduster@gmail.com>2023-02-26 19:26:33 +0200
committerbitsawer <sawerduster@gmail.com>2023-02-26 19:26:33 +0200
commit61219aeed6e6c390877254cd622195896f6efb85 (patch)
tree214dbfb491151019262775f8f1f2f4d39ce03025 /pygments
parentf589ac658924518894e18a38061eb00793a3b0a9 (diff)
downloadpygments-git-61219aeed6e6c390877254cd622195896f6efb85.tar.gz
Fix GLSL and HLSL preprocessor directive start
Diffstat (limited to 'pygments')
-rw-r--r--pygments/lexers/graphics.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/pygments/lexers/graphics.py b/pygments/lexers/graphics.py
index 146bb744..63c76373 100644
--- a/pygments/lexers/graphics.py
+++ b/pygments/lexers/graphics.py
@@ -30,7 +30,7 @@ class GLShaderLexer(RegexLexer):
tokens = {
'root': [
- (r'^#(?:.*\\\n)*.*$', Comment.Preproc),
+ (r'#(?:.*\\\n)*.*$', Comment.Preproc),
(r'//.*$', Comment.Single),
(r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
(r'\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?',
@@ -161,7 +161,7 @@ class HLSLShaderLexer(RegexLexer):
tokens = {
'root': [
- (r'^#(?:.*\\\n)*.*$', Comment.Preproc),
+ (r'#(?:.*\\\n)*.*$', Comment.Preproc),
(r'//.*$', Comment.Single),
(r'/(\\\n)?[*](.|\n)*?[*](\\\n)?/', Comment.Multiline),
(r'\+|-|~|!=?|\*|/|%|<<|>>|<=?|>=?|==?|&&?|\^|\|\|?',