lib/rouge/lexers/perl.rb in rouge-3.1.0 vs lib/rouge/lexers/perl.rb in rouge-3.1.1
- old
+ new
@@ -102,10 +102,11 @@
rule /<<([\'"]?)([a-zA-Z_][a-zA-Z0-9_]*)\1;?\n.*?\n\2\n/m, Str
rule /__END__\b/, Comment::Preproc, :end_part
rule /\$\^[ADEFHILMOPSTWX]/, Name::Variable::Global
rule /\$[\\"'\[\]&`+*.,;=%~?@$!<>(^\|\/-](?!\w)/, Name::Variable::Global
+ rule /[-+\/*%=<>&^\|!\\~]=?/, Operator
rule /[$@%#]+/, Name::Variable, :varname
rule /0_?[0-7]+(_[0-7]+)*/, Num::Oct
rule /0x[0-9A-Fa-f]+(_[0-9A-Fa-f]+)*/, Num::Hex
rule /0b[01]+(_[01]+)*/, Num::Bin
@@ -126,10 +127,9 @@
rule /package\s+/, Keyword, :modulename
rule /sub\s+/, Keyword, :funcname
rule /\[\]|\*\*|::|<<|>>|>=|<=|<=>|={3}|!=|=~|!~|&&?|\|\||\.{1,3}/,
Operator
- rule /[-+\/*%=<>&^\|!\\~]=?/, Operator
rule /[()\[\]:;,<>\/?{}]/, Punctuation
rule(/(?=\w)/) { push :name }
end
state :format do