Commits

Tim Hatch committed 63aed87

Fix operator highlighting in Monkey lexer.

Comments (0)

Files changed (2)

pygments/lexers/compiled.py

             # Array
             (r'[\[\]]', Punctuation),
             # Other
-            (r'<=|>=|<>|[*]=|/=|[+]=|-=|&=|~=|\[|\]=|[-&*/^+=<>]', Operator),
+            (r'<=|>=|<>|\*=|/=|\+=|-=|&=|~=|\|=|[-&*/^+=<>|~]', Operator),
             (r'(?i)(?:Not|Mod|Shl|Shr|And|Or)', Operator.Word),
             (r'[\(\){}!#,.:]', Punctuation),
             # catch the rest

tests/examplefiles/example.monkey

 #SOMETHING = True
 #Print SOMETHING
 #If SOMETHING
-#End
+#End
+
+' operators
+Global a = 32
+Global b = 32 ~ 0
+b ~= 16
+b |= 16
+b &= 16
+Global c = a | b