summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--pygments/lexers/_mapping.py1
-rw-r--r--pygments/lexers/golo.py17
2 files changed, 5 insertions, 13 deletions
diff --git a/pygments/lexers/_mapping.py b/pygments/lexers/_mapping.py
index 669357e0..b90e0d8f 100644
--- a/pygments/lexers/_mapping.py
+++ b/pygments/lexers/_mapping.py
@@ -128,6 +128,7 @@ LEXERS = {
'GnuplotLexer': ('pygments.lexers.other', 'Gnuplot', ('gnuplot',), ('*.plot', '*.plt'), ('text/x-gnuplot',)),
'GoLexer': ('pygments.lexers.compiled', 'Go', ('go',), ('*.go',), ('text/x-gosrc',)),
'GoloLexer': ('pygments.lexers.golo', 'Golo', ('golo',), ('*.golo',), ()),
+ 'SimpleMarkdownLexer': ('pygments.lexers.golo', 'Markdown', ('markdown',), ('*.mkd',), ()),
'GoodDataCLLexer': ('pygments.lexers.other', 'GoodData-CL', ('gooddata-cl',), ('*.gdc',), ('text/x-gooddata-cl',)),
'GosuLexer': ('pygments.lexers.jvm', 'Gosu', ('gosu',), ('*.gs', '*.gsx', '*.gsp', '*.vark'), ('text/x-gosu',)),
'GosuTemplateLexer': ('pygments.lexers.jvm', 'Gosu Template', ('gst',), ('*.gst',), ('text/x-gosu-template',)),
diff --git a/pygments/lexers/golo.py b/pygments/lexers/golo.py
index 02fbb5b7..8cf5a398 100644
--- a/pygments/lexers/golo.py
+++ b/pygments/lexers/golo.py
@@ -32,8 +32,10 @@ class GoloLexer(RegexLexer):
(r'#.*$', Comment),
- (r'(\^|\.\.\.|:|\?:|->|==|!=|=|\+|-|\*|%|/|<|<=|>|>=|=|\.)',
+ (r'(\^|\.\.\.|:|\?:|->|==|!=|=|\+|\*|%|/|<|<=|>|>=|=|\.)',
Operator),
+ (r'(?<=[^-])(-)(?=[^-])', Operator),
+
(r'(is|isnt|and|or|not|oftype|in|orIfNull)\b', Operator.Word),
(r'[]{}|(),[]', Punctuation),
@@ -80,7 +82,7 @@ class GoloLexer(RegexLexer):
(r'"""', String, combined('stringescape', 'triplestring')),
(r'"', String, combined('stringescape', 'doublestring')),
(r"'", String, combined('stringescape', 'singlestring')),
- (r'----', String.Doc, 'doc'),
+ (r'----((.|\n)*?)----', String.Doc)
],
@@ -117,15 +119,4 @@ class GoloLexer(RegexLexer):
(r"'", String, '#pop'),
include('string'),
],
- 'doc': [
- (r'----', String.Doc, '#pop'),
- (r'#\s+.*#?$', Generic.Heading),
- (r'##+\s+.*#?$', Generic.Subheading),
- (r'\*[^*]+\*', Generic.Emph),
- (r'_[^_]+_', Generic.Emph),
- (r'\*\*[^*]+\*\*', Generic.Strong),
- (r'__[^_]+__', Generic.Strong),
- #(r'`(.*?)`', using(GoloLexer)),
- ],
-
}