From d6909112bc9d375350a8c4701862635f834d30c5 Mon Sep 17 00:00:00 2001 From: Ashwin Maroli Date: Sun, 18 Mar 2018 19:06:31 +0530 Subject: [PATCH] add frozen_string_literal: true magic comment --- lib/rouge.rb | 1 + lib/rouge/cli.rb | 3 ++- lib/rouge/formatter.rb | 3 ++- lib/rouge/formatters/html.rb | 1 + lib/rouge/formatters/html_inline.rb | 1 + lib/rouge/formatters/html_legacy.rb | 1 + lib/rouge/formatters/html_linewise.rb | 1 + lib/rouge/formatters/html_pygments.rb | 2 ++ lib/rouge/formatters/html_table.rb | 3 ++- lib/rouge/formatters/null.rb | 1 + lib/rouge/formatters/terminal256.rb | 1 + lib/rouge/guesser.rb | 2 ++ lib/rouge/guessers/disambiguation.rb | 2 ++ lib/rouge/guessers/filename.rb | 2 ++ lib/rouge/guessers/glob_mapping.rb | 2 ++ lib/rouge/guessers/mimetype.rb | 2 ++ lib/rouge/guessers/modeline.rb | 2 ++ lib/rouge/guessers/source.rb | 2 ++ lib/rouge/guessers/util.rb | 2 ++ lib/rouge/lexer.rb | 1 + lib/rouge/lexers/abap.rb | 2 ++ lib/rouge/lexers/actionscript.rb | 1 + lib/rouge/lexers/apache.rb | 2 ++ lib/rouge/lexers/apiblueprint.rb | 2 ++ lib/rouge/lexers/apple_script.rb | 2 ++ lib/rouge/lexers/awk.rb | 1 + lib/rouge/lexers/biml.rb | 2 ++ lib/rouge/lexers/bsl.rb | 1 + lib/rouge/lexers/c.rb | 1 + lib/rouge/lexers/ceylon.rb | 1 + lib/rouge/lexers/cfscript.rb | 1 + lib/rouge/lexers/clojure.rb | 1 + lib/rouge/lexers/cmake.rb | 1 + lib/rouge/lexers/coffeescript.rb | 1 + lib/rouge/lexers/common_lisp.rb | 1 + lib/rouge/lexers/conf.rb | 1 + lib/rouge/lexers/console.rb | 1 + lib/rouge/lexers/coq.rb | 1 + lib/rouge/lexers/cpp.rb | 1 + lib/rouge/lexers/csharp.rb | 1 + lib/rouge/lexers/css.rb | 1 + lib/rouge/lexers/d.rb | 1 + lib/rouge/lexers/dart.rb | 1 + lib/rouge/lexers/diff.rb | 2 ++ lib/rouge/lexers/digdag.rb | 2 ++ lib/rouge/lexers/docker.rb | 1 + lib/rouge/lexers/dot.rb | 1 + lib/rouge/lexers/eiffel.rb | 1 + lib/rouge/lexers/elixir.rb | 1 + lib/rouge/lexers/elm.rb | 1 + lib/rouge/lexers/erb.rb | 1 + lib/rouge/lexers/erlang.rb | 1 + lib/rouge/lexers/factor.rb | 1 + lib/rouge/lexers/fortran.rb | 2 ++ lib/rouge/lexers/fsharp.rb | 1 + lib/rouge/lexers/gherkin.rb | 1 + lib/rouge/lexers/glsl.rb | 1 + lib/rouge/lexers/go.rb | 1 + lib/rouge/lexers/gradle.rb | 1 + lib/rouge/lexers/graphql.rb | 1 + lib/rouge/lexers/groovy.rb | 1 + lib/rouge/lexers/hack.rb | 1 + lib/rouge/lexers/haml.rb | 1 + lib/rouge/lexers/handlebars.rb | 1 + lib/rouge/lexers/haskell.rb | 1 + lib/rouge/lexers/html.rb | 1 + lib/rouge/lexers/http.rb | 1 + lib/rouge/lexers/hylang.rb | 1 + lib/rouge/lexers/idlang.rb | 2 ++ lib/rouge/lexers/igorpro.rb | 1 + lib/rouge/lexers/ini.rb | 1 + lib/rouge/lexers/io.rb | 1 + lib/rouge/lexers/irb.rb | 1 + lib/rouge/lexers/java.rb | 1 + lib/rouge/lexers/javascript.rb | 1 + lib/rouge/lexers/jinja.rb | 1 + lib/rouge/lexers/json.rb | 1 + lib/rouge/lexers/json_doc.rb | 1 + lib/rouge/lexers/jsonnet.rb | 1 + lib/rouge/lexers/jsx.rb | 2 ++ lib/rouge/lexers/julia.rb | 1 + lib/rouge/lexers/kotlin.rb | 1 + lib/rouge/lexers/lasso.rb | 1 + lib/rouge/lexers/liquid.rb | 1 + lib/rouge/lexers/literate_coffeescript.rb | 1 + lib/rouge/lexers/literate_haskell.rb | 1 + lib/rouge/lexers/llvm.rb | 1 + lib/rouge/lexers/lua.rb | 1 + lib/rouge/lexers/make.rb | 1 + lib/rouge/lexers/markdown.rb | 1 + lib/rouge/lexers/matlab.rb | 1 + lib/rouge/lexers/moonscript.rb | 1 + lib/rouge/lexers/mosel.rb | 1 + lib/rouge/lexers/mxml.rb | 1 + lib/rouge/lexers/nasm.rb | 1 + lib/rouge/lexers/nginx.rb | 1 + lib/rouge/lexers/nim.rb | 1 + lib/rouge/lexers/nix.rb | 1 + lib/rouge/lexers/objective_c.rb | 1 + lib/rouge/lexers/ocaml.rb | 1 + lib/rouge/lexers/pascal.rb | 1 + lib/rouge/lexers/perl.rb | 1 + lib/rouge/lexers/php.rb | 1 + lib/rouge/lexers/php/builtins.rb | 2 ++ lib/rouge/lexers/plain_text.rb | 1 + lib/rouge/lexers/plist.rb | 2 ++ lib/rouge/lexers/pony.rb | 1 + lib/rouge/lexers/powershell.rb | 1 + lib/rouge/lexers/praat.rb | 1 + lib/rouge/lexers/prolog.rb | 1 + lib/rouge/lexers/prometheus.rb | 2 ++ lib/rouge/lexers/properties.rb | 1 + lib/rouge/lexers/protobuf.rb | 1 + lib/rouge/lexers/puppet.rb | 1 + lib/rouge/lexers/python.rb | 1 + lib/rouge/lexers/q.rb | 2 ++ lib/rouge/lexers/qml.rb | 1 + lib/rouge/lexers/r.rb | 1 + lib/rouge/lexers/racket.rb | 2 ++ lib/rouge/lexers/ruby.rb | 1 + lib/rouge/lexers/rust.rb | 1 + lib/rouge/lexers/sass.rb | 1 + lib/rouge/lexers/sass/common.rb | 1 + lib/rouge/lexers/scala.rb | 1 + lib/rouge/lexers/scheme.rb | 1 + lib/rouge/lexers/scss.rb | 1 + lib/rouge/lexers/sed.rb | 1 + lib/rouge/lexers/shell.rb | 1 + lib/rouge/lexers/sieve.rb | 1 + lib/rouge/lexers/slim.rb | 1 + lib/rouge/lexers/smalltalk.rb | 1 + lib/rouge/lexers/smarty.rb | 1 + lib/rouge/lexers/sml.rb | 1 + lib/rouge/lexers/sql.rb | 1 + lib/rouge/lexers/swift.rb | 1 + lib/rouge/lexers/tap.rb | 2 ++ lib/rouge/lexers/tcl.rb | 1 + lib/rouge/lexers/tex.rb | 1 + lib/rouge/lexers/toml.rb | 1 + lib/rouge/lexers/tsx.rb | 1 + lib/rouge/lexers/tulip.rb | 2 ++ lib/rouge/lexers/turtle.rb | 1 + lib/rouge/lexers/twig.rb | 1 + lib/rouge/lexers/typescript.rb | 1 + lib/rouge/lexers/typescript/common.rb | 1 + lib/rouge/lexers/vala.rb | 1 + lib/rouge/lexers/vb.rb | 1 + lib/rouge/lexers/verilog.rb | 1 + lib/rouge/lexers/vhdl.rb | 1 + lib/rouge/lexers/viml.rb | 1 + lib/rouge/lexers/vue.rb | 2 ++ lib/rouge/lexers/wollok.rb | 1 + lib/rouge/lexers/xml.rb | 1 + lib/rouge/lexers/yaml.rb | 1 + lib/rouge/plugins/redcarpet.rb | 1 + lib/rouge/regex_lexer.rb | 1 + lib/rouge/template_lexer.rb | 1 + lib/rouge/text_analyzer.rb | 1 + lib/rouge/theme.rb | 1 + lib/rouge/themes/base16.rb | 1 + lib/rouge/themes/colorful.rb | 1 + lib/rouge/themes/github.rb | 1 + lib/rouge/themes/gruvbox.rb | 1 + lib/rouge/themes/igor_pro.rb | 1 + lib/rouge/themes/molokai.rb | 1 + lib/rouge/themes/monokai.rb | 1 + lib/rouge/themes/monokai_sublime.rb | 2 ++ lib/rouge/themes/pastie.rb | 1 + lib/rouge/themes/thankful_eyes.rb | 1 + lib/rouge/themes/tulip.rb | 1 + lib/rouge/token.rb | 1 + lib/rouge/util.rb | 1 + lib/rouge/version.rb | 1 + tasks/gherkin.rake | 2 ++ tasks/lua.rake | 2 ++ tasks/matlab.rake | 2 ++ tasks/php.rake | 2 ++ tasks/vim.rake | 2 ++ 178 files changed, 214 insertions(+), 3 deletions(-) diff --git a/lib/rouge.rb b/lib/rouge.rb index ac049c3f53..0877d8536e 100644 --- a/lib/rouge.rb +++ b/lib/rouge.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # stdlib require 'pathname' diff --git a/lib/rouge/cli.rb b/lib/rouge/cli.rb index a8ce3d159b..f120c0cb08 100644 --- a/lib/rouge/cli.rb +++ b/lib/rouge/cli.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # not required by the main lib. # to use this module, require 'rouge/cli'. @@ -363,7 +364,7 @@ def run puts "== Available Lexers ==" Lexer.all.sort_by(&:tag).each do |lexer| - desc = "#{lexer.desc}" + desc = String.new("#{lexer.desc}") if lexer.aliases.any? desc << " [aliases: #{lexer.aliases.join(',')}]" end diff --git a/lib/rouge/formatter.rb b/lib/rouge/formatter.rb index 8dddb94783..6eeb177fd7 100644 --- a/lib/rouge/formatter.rb +++ b/lib/rouge/formatter.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge # A Formatter takes a token stream and formats it for human viewing. @@ -33,7 +34,7 @@ def initialize(opts={}) def format(tokens, &b) return stream(tokens, &b) if block_given? - out = '' + out = String.new('') stream(tokens) { |piece| out << piece } out diff --git a/lib/rouge/formatters/html.rb b/lib/rouge/formatters/html.rb index 2093a34e2b..de98dce804 100644 --- a/lib/rouge/formatters/html.rb +++ b/lib/rouge/formatters/html.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters diff --git a/lib/rouge/formatters/html_inline.rb b/lib/rouge/formatters/html_inline.rb index b41f70c0cd..e7f34399b2 100644 --- a/lib/rouge/formatters/html_inline.rb +++ b/lib/rouge/formatters/html_inline.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters diff --git a/lib/rouge/formatters/html_legacy.rb b/lib/rouge/formatters/html_legacy.rb index 813cefb81f..8327564531 100644 --- a/lib/rouge/formatters/html_legacy.rb +++ b/lib/rouge/formatters/html_legacy.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # stdlib require 'cgi' diff --git a/lib/rouge/formatters/html_linewise.rb b/lib/rouge/formatters/html_linewise.rb index 55c8e72ae9..9510aa600a 100644 --- a/lib/rouge/formatters/html_linewise.rb +++ b/lib/rouge/formatters/html_linewise.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters diff --git a/lib/rouge/formatters/html_pygments.rb b/lib/rouge/formatters/html_pygments.rb index ea895ea517..8ed8f54839 100644 --- a/lib/rouge/formatters/html_pygments.rb +++ b/lib/rouge/formatters/html_pygments.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Formatters class HTMLPygments < Formatter diff --git a/lib/rouge/formatters/html_table.rb b/lib/rouge/formatters/html_table.rb index 42586d7281..01d94e4bdb 100644 --- a/lib/rouge/formatters/html_table.rb +++ b/lib/rouge/formatters/html_table.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters @@ -22,7 +23,7 @@ def style(scope) def stream(tokens, &b) num_lines = 0 last_val = '' - formatted = '' + formatted = String.new('') tokens.each do |tok, val| last_val = val diff --git a/lib/rouge/formatters/null.rb b/lib/rouge/formatters/null.rb index 01036d9a26..078c461ca9 100644 --- a/lib/rouge/formatters/null.rb +++ b/lib/rouge/formatters/null.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters diff --git a/lib/rouge/formatters/terminal256.rb b/lib/rouge/formatters/terminal256.rb index d5ba2e3314..b9af6a8297 100644 --- a/lib/rouge/formatters/terminal256.rb +++ b/lib/rouge/formatters/terminal256.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Formatters diff --git a/lib/rouge/guesser.rb b/lib/rouge/guesser.rb index 6fa35c094b..7cfc3e676c 100644 --- a/lib/rouge/guesser.rb +++ b/lib/rouge/guesser.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge class Guesser class Ambiguous < StandardError diff --git a/lib/rouge/guessers/disambiguation.rb b/lib/rouge/guessers/disambiguation.rb index 59f1a6af2e..de4af450e7 100644 --- a/lib/rouge/guessers/disambiguation.rb +++ b/lib/rouge/guessers/disambiguation.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers class Disambiguation < Guesser diff --git a/lib/rouge/guessers/filename.rb b/lib/rouge/guessers/filename.rb index f26bc04ab1..2f01b4c9d8 100644 --- a/lib/rouge/guessers/filename.rb +++ b/lib/rouge/guessers/filename.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers class Filename < Guesser diff --git a/lib/rouge/guessers/glob_mapping.rb b/lib/rouge/guessers/glob_mapping.rb index f703ac6e81..f635328f64 100644 --- a/lib/rouge/guessers/glob_mapping.rb +++ b/lib/rouge/guessers/glob_mapping.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers # This class allows for custom behavior diff --git a/lib/rouge/guessers/mimetype.rb b/lib/rouge/guessers/mimetype.rb index c5ef01787a..92a1d43e15 100644 --- a/lib/rouge/guessers/mimetype.rb +++ b/lib/rouge/guessers/mimetype.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers class Mimetype < Guesser diff --git a/lib/rouge/guessers/modeline.rb b/lib/rouge/guessers/modeline.rb index 316e4bb892..60f0c556e1 100644 --- a/lib/rouge/guessers/modeline.rb +++ b/lib/rouge/guessers/modeline.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers class Modeline < Guesser diff --git a/lib/rouge/guessers/source.rb b/lib/rouge/guessers/source.rb index b1f8dbf810..b3e90cbb76 100644 --- a/lib/rouge/guessers/source.rb +++ b/lib/rouge/guessers/source.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers class Source < Guesser diff --git a/lib/rouge/guessers/util.rb b/lib/rouge/guessers/util.rb index e4499ea7cf..89c50bec98 100644 --- a/lib/rouge/guessers/util.rb +++ b/lib/rouge/guessers/util.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Guessers module Util diff --git a/lib/rouge/lexer.rb b/lib/rouge/lexer.rb index cc86a63d19..7fd93db25b 100644 --- a/lib/rouge/lexer.rb +++ b/lib/rouge/lexer.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # stdlib require 'strscan' diff --git a/lib/rouge/lexers/abap.rb b/lib/rouge/lexers/abap.rb index 6e1f9f5b01..01137721ed 100644 --- a/lib/rouge/lexers/abap.rb +++ b/lib/rouge/lexers/abap.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + # ABAP elements taken from http://help.sap.com/abapdocu_750/en/index.htm?file=abapdo.htm module Rouge diff --git a/lib/rouge/lexers/actionscript.rb b/lib/rouge/lexers/actionscript.rb index cfe5d7c360..4db4b72312 100644 --- a/lib/rouge/lexers/actionscript.rb +++ b/lib/rouge/lexers/actionscript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/apache.rb b/lib/rouge/lexers/apache.rb index ad35d69ec8..e07390e347 100644 --- a/lib/rouge/lexers/apache.rb +++ b/lib/rouge/lexers/apache.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + require 'yaml' module Rouge diff --git a/lib/rouge/lexers/apiblueprint.rb b/lib/rouge/lexers/apiblueprint.rb index ef5d4a9794..7695c39081 100644 --- a/lib/rouge/lexers/apiblueprint.rb +++ b/lib/rouge/lexers/apiblueprint.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers load_lexer 'markdown.rb' diff --git a/lib/rouge/lexers/apple_script.rb b/lib/rouge/lexers/apple_script.rb index 785a215917..cc01bf2f7e 100644 --- a/lib/rouge/lexers/apple_script.rb +++ b/lib/rouge/lexers/apple_script.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + module Rouge module Lexers class AppleScript < RegexLexer diff --git a/lib/rouge/lexers/awk.rb b/lib/rouge/lexers/awk.rb index 9d3deab7c0..257e72b3bd 100644 --- a/lib/rouge/lexers/awk.rb +++ b/lib/rouge/lexers/awk.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/biml.rb b/lib/rouge/lexers/biml.rb index ca0cdbfc85..bc8e82858a 100644 --- a/lib/rouge/lexers/biml.rb +++ b/lib/rouge/lexers/biml.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers load_lexer 'xml.rb' diff --git a/lib/rouge/lexers/bsl.rb b/lib/rouge/lexers/bsl.rb index a42ef56db1..92fe471410 100644 --- a/lib/rouge/lexers/bsl.rb +++ b/lib/rouge/lexers/bsl.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/c.rb b/lib/rouge/lexers/c.rb index d2f246b53f..89ac83125b 100644 --- a/lib/rouge/lexers/c.rb +++ b/lib/rouge/lexers/c.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/ceylon.rb b/lib/rouge/lexers/ceylon.rb index e96ac20896..c06bfd041a 100644 --- a/lib/rouge/lexers/ceylon.rb +++ b/lib/rouge/lexers/ceylon.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/cfscript.rb b/lib/rouge/lexers/cfscript.rb index d3f65a0c3c..149ad60185 100644 --- a/lib/rouge/lexers/cfscript.rb +++ b/lib/rouge/lexers/cfscript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/clojure.rb b/lib/rouge/lexers/clojure.rb index 5614368ec0..68f2048936 100644 --- a/lib/rouge/lexers/clojure.rb +++ b/lib/rouge/lexers/clojure.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/cmake.rb b/lib/rouge/lexers/cmake.rb index 57342e39a5..a11c68dfbd 100644 --- a/lib/rouge/lexers/cmake.rb +++ b/lib/rouge/lexers/cmake.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/coffeescript.rb b/lib/rouge/lexers/coffeescript.rb index 324877ac97..4eafc78c17 100644 --- a/lib/rouge/lexers/coffeescript.rb +++ b/lib/rouge/lexers/coffeescript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/common_lisp.rb b/lib/rouge/lexers/common_lisp.rb index f5426a4b96..9357fa2997 100644 --- a/lib/rouge/lexers/common_lisp.rb +++ b/lib/rouge/lexers/common_lisp.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/conf.rb b/lib/rouge/lexers/conf.rb index 6815c469ab..f4722fbab2 100644 --- a/lib/rouge/lexers/conf.rb +++ b/lib/rouge/lexers/conf.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/console.rb b/lib/rouge/lexers/console.rb index 0a2b672785..30ab082ca9 100644 --- a/lib/rouge/lexers/console.rb +++ b/lib/rouge/lexers/console.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/coq.rb b/lib/rouge/lexers/coq.rb index 6e4a752b48..2067019595 100644 --- a/lib/rouge/lexers/coq.rb +++ b/lib/rouge/lexers/coq.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/cpp.rb b/lib/rouge/lexers/cpp.rb index 5aec1e950c..83280bb778 100644 --- a/lib/rouge/lexers/cpp.rb +++ b/lib/rouge/lexers/cpp.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/csharp.rb b/lib/rouge/lexers/csharp.rb index 0e504b2ed4..7dc4fd52c3 100644 --- a/lib/rouge/lexers/csharp.rb +++ b/lib/rouge/lexers/csharp.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/css.rb b/lib/rouge/lexers/css.rb index eb86093da5..4792434470 100644 --- a/lib/rouge/lexers/css.rb +++ b/lib/rouge/lexers/css.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/d.rb b/lib/rouge/lexers/d.rb index a985e1d106..be8be00112 100644 --- a/lib/rouge/lexers/d.rb +++ b/lib/rouge/lexers/d.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/dart.rb b/lib/rouge/lexers/dart.rb index e1884a1226..37237ed11d 100644 --- a/lib/rouge/lexers/dart.rb +++ b/lib/rouge/lexers/dart.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/diff.rb b/lib/rouge/lexers/diff.rb index b34ebe7083..0f44832392 100644 --- a/lib/rouge/lexers/diff.rb +++ b/lib/rouge/lexers/diff.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Diff < RegexLexer diff --git a/lib/rouge/lexers/digdag.rb b/lib/rouge/lexers/digdag.rb index e6f719e30e..f9c6c7d80c 100644 --- a/lib/rouge/lexers/digdag.rb +++ b/lib/rouge/lexers/digdag.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + require 'set' module Rouge module Lexers diff --git a/lib/rouge/lexers/docker.rb b/lib/rouge/lexers/docker.rb index f65663e6ac..22c6b07144 100644 --- a/lib/rouge/lexers/docker.rb +++ b/lib/rouge/lexers/docker.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/dot.rb b/lib/rouge/lexers/dot.rb index 542e4ac04c..5e358d7068 100644 --- a/lib/rouge/lexers/dot.rb +++ b/lib/rouge/lexers/dot.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/eiffel.rb b/lib/rouge/lexers/eiffel.rb index 67ae66759c..46f5a004c9 100644 --- a/lib/rouge/lexers/eiffel.rb +++ b/lib/rouge/lexers/eiffel.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/elixir.rb b/lib/rouge/lexers/elixir.rb index 4a6e277525..68175e3ce4 100644 --- a/lib/rouge/lexers/elixir.rb +++ b/lib/rouge/lexers/elixir.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/elm.rb b/lib/rouge/lexers/elm.rb index 56f2c53420..80335fbcda 100644 --- a/lib/rouge/lexers/elm.rb +++ b/lib/rouge/lexers/elm.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/erb.rb b/lib/rouge/lexers/erb.rb index b2883b097c..5adf54b795 100644 --- a/lib/rouge/lexers/erb.rb +++ b/lib/rouge/lexers/erb.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/erlang.rb b/lib/rouge/lexers/erlang.rb index 5d03b46fad..031f2bd2bc 100644 --- a/lib/rouge/lexers/erlang.rb +++ b/lib/rouge/lexers/erlang.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/factor.rb b/lib/rouge/lexers/factor.rb index 5ea7cb41e2..267bcf3c40 100644 --- a/lib/rouge/lexers/factor.rb +++ b/lib/rouge/lexers/factor.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/fortran.rb b/lib/rouge/lexers/fortran.rb index 721f38b9a5..1341340734 100644 --- a/lib/rouge/lexers/fortran.rb +++ b/lib/rouge/lexers/fortran.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + # vim: set ts=2 sw=2 et: # TODO: Implement format list support. diff --git a/lib/rouge/lexers/fsharp.rb b/lib/rouge/lexers/fsharp.rb index df5738524e..d171f0805f 100644 --- a/lib/rouge/lexers/fsharp.rb +++ b/lib/rouge/lexers/fsharp.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/gherkin.rb b/lib/rouge/lexers/gherkin.rb index cbdc6c6d9a..d45b29c42b 100644 --- a/lib/rouge/lexers/gherkin.rb +++ b/lib/rouge/lexers/gherkin.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/glsl.rb b/lib/rouge/lexers/glsl.rb index bff367461a..a9227ff36e 100644 --- a/lib/rouge/lexers/glsl.rb +++ b/lib/rouge/lexers/glsl.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/go.rb b/lib/rouge/lexers/go.rb index 443b96db3a..4a4837c88f 100644 --- a/lib/rouge/lexers/go.rb +++ b/lib/rouge/lexers/go.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/gradle.rb b/lib/rouge/lexers/gradle.rb index 8bf12cc8fc..27b5f967eb 100644 --- a/lib/rouge/lexers/gradle.rb +++ b/lib/rouge/lexers/gradle.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/graphql.rb b/lib/rouge/lexers/graphql.rb index f4fba4b38f..0277638b61 100644 --- a/lib/rouge/lexers/graphql.rb +++ b/lib/rouge/lexers/graphql.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/groovy.rb b/lib/rouge/lexers/groovy.rb index 43774f4608..5d470d54db 100644 --- a/lib/rouge/lexers/groovy.rb +++ b/lib/rouge/lexers/groovy.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/hack.rb b/lib/rouge/lexers/hack.rb index 1acf69b296..203e9a756a 100644 --- a/lib/rouge/lexers/hack.rb +++ b/lib/rouge/lexers/hack.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/haml.rb b/lib/rouge/lexers/haml.rb index 5466224e3e..3f19bc459d 100644 --- a/lib/rouge/lexers/haml.rb +++ b/lib/rouge/lexers/haml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/handlebars.rb b/lib/rouge/lexers/handlebars.rb index 5ac8618862..8f9aac4acc 100644 --- a/lib/rouge/lexers/handlebars.rb +++ b/lib/rouge/lexers/handlebars.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/haskell.rb b/lib/rouge/lexers/haskell.rb index aa3fe00612..32f94d9df5 100644 --- a/lib/rouge/lexers/haskell.rb +++ b/lib/rouge/lexers/haskell.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/html.rb b/lib/rouge/lexers/html.rb index 3de6d44516..d2f9ddda81 100644 --- a/lib/rouge/lexers/html.rb +++ b/lib/rouge/lexers/html.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/http.rb b/lib/rouge/lexers/http.rb index 0fc4d7443b..75cbe07793 100644 --- a/lib/rouge/lexers/http.rb +++ b/lib/rouge/lexers/http.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/hylang.rb b/lib/rouge/lexers/hylang.rb index 1c1c6374ad..4592ba23eb 100644 --- a/lib/rouge/lexers/hylang.rb +++ b/lib/rouge/lexers/hylang.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/idlang.rb b/lib/rouge/lexers/idlang.rb index 0cacfcb454..47a61b9f55 100644 --- a/lib/rouge/lexers/idlang.rb +++ b/lib/rouge/lexers/idlang.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + # vim: set ts=2 sw=2 et: module Rouge diff --git a/lib/rouge/lexers/igorpro.rb b/lib/rouge/lexers/igorpro.rb index 1a13fd0cf8..ae8a606926 100644 --- a/lib/rouge/lexers/igorpro.rb +++ b/lib/rouge/lexers/igorpro.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/ini.rb b/lib/rouge/lexers/ini.rb index f819cf33cd..a05fa42761 100644 --- a/lib/rouge/lexers/ini.rb +++ b/lib/rouge/lexers/ini.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/io.rb b/lib/rouge/lexers/io.rb index 01a3663c92..92dd1265c9 100644 --- a/lib/rouge/lexers/io.rb +++ b/lib/rouge/lexers/io.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/irb.rb b/lib/rouge/lexers/irb.rb index b35a297499..b7fc3963c1 100644 --- a/lib/rouge/lexers/irb.rb +++ b/lib/rouge/lexers/irb.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/java.rb b/lib/rouge/lexers/java.rb index 2322dd9422..2a51fcc973 100644 --- a/lib/rouge/lexers/java.rb +++ b/lib/rouge/lexers/java.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/javascript.rb b/lib/rouge/lexers/javascript.rb index 3b87ff70f8..bbce102b36 100644 --- a/lib/rouge/lexers/javascript.rb +++ b/lib/rouge/lexers/javascript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/jinja.rb b/lib/rouge/lexers/jinja.rb index f159c26394..4ee76bbca6 100644 --- a/lib/rouge/lexers/jinja.rb +++ b/lib/rouge/lexers/jinja.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/json.rb b/lib/rouge/lexers/json.rb index 37a5bd6caa..d8c3e27d6a 100644 --- a/lib/rouge/lexers/json.rb +++ b/lib/rouge/lexers/json.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/json_doc.rb b/lib/rouge/lexers/json_doc.rb index 9b5c2b0d3d..6b33fd1347 100644 --- a/lib/rouge/lexers/json_doc.rb +++ b/lib/rouge/lexers/json_doc.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/jsonnet.rb b/lib/rouge/lexers/jsonnet.rb index 9502f19738..361c442712 100644 --- a/lib/rouge/lexers/jsonnet.rb +++ b/lib/rouge/lexers/jsonnet.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/jsx.rb b/lib/rouge/lexers/jsx.rb index 8daff5fd29..2af58f0c9f 100644 --- a/lib/rouge/lexers/jsx.rb +++ b/lib/rouge/lexers/jsx.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers load_lexer 'javascript.rb' diff --git a/lib/rouge/lexers/julia.rb b/lib/rouge/lexers/julia.rb index 4e3a3dc182..62a64c602f 100644 --- a/lib/rouge/lexers/julia.rb +++ b/lib/rouge/lexers/julia.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/kotlin.rb b/lib/rouge/lexers/kotlin.rb index cb993d47f6..e78ed7503c 100644 --- a/lib/rouge/lexers/kotlin.rb +++ b/lib/rouge/lexers/kotlin.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/lasso.rb b/lib/rouge/lexers/lasso.rb index 24f1735255..6be6304bce 100644 --- a/lib/rouge/lexers/lasso.rb +++ b/lib/rouge/lexers/lasso.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true require 'yaml' diff --git a/lib/rouge/lexers/liquid.rb b/lib/rouge/lexers/liquid.rb index c199196820..60a6130e05 100644 --- a/lib/rouge/lexers/liquid.rb +++ b/lib/rouge/lexers/liquid.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/literate_coffeescript.rb b/lib/rouge/lexers/literate_coffeescript.rb index 0c546ca614..d2a54c0b8a 100644 --- a/lib/rouge/lexers/literate_coffeescript.rb +++ b/lib/rouge/lexers/literate_coffeescript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/literate_haskell.rb b/lib/rouge/lexers/literate_haskell.rb index d8708aaf3e..f4804d0653 100644 --- a/lib/rouge/lexers/literate_haskell.rb +++ b/lib/rouge/lexers/literate_haskell.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/llvm.rb b/lib/rouge/lexers/llvm.rb index 521933f6d2..277e3212b5 100644 --- a/lib/rouge/lexers/llvm.rb +++ b/lib/rouge/lexers/llvm.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/lua.rb b/lib/rouge/lexers/lua.rb index a22db63bc7..6b0cc8be24 100644 --- a/lib/rouge/lexers/lua.rb +++ b/lib/rouge/lexers/lua.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/make.rb b/lib/rouge/lexers/make.rb index 66992cc92f..4b85264b96 100644 --- a/lib/rouge/lexers/make.rb +++ b/lib/rouge/lexers/make.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/markdown.rb b/lib/rouge/lexers/markdown.rb index 76710b5e03..41c949ca6b 100644 --- a/lib/rouge/lexers/markdown.rb +++ b/lib/rouge/lexers/markdown.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/matlab.rb b/lib/rouge/lexers/matlab.rb index ea42c2a190..ecd378d79e 100644 --- a/lib/rouge/lexers/matlab.rb +++ b/lib/rouge/lexers/matlab.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/moonscript.rb b/lib/rouge/lexers/moonscript.rb index ac3c8f2d6a..229ba147dc 100644 --- a/lib/rouge/lexers/moonscript.rb +++ b/lib/rouge/lexers/moonscript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/mosel.rb b/lib/rouge/lexers/mosel.rb index 54a8d7a30c..a87a2b1bbc 100644 --- a/lib/rouge/lexers/mosel.rb +++ b/lib/rouge/lexers/mosel.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/mxml.rb b/lib/rouge/lexers/mxml.rb index 7055e2571c..6342281e1e 100644 --- a/lib/rouge/lexers/mxml.rb +++ b/lib/rouge/lexers/mxml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/nasm.rb b/lib/rouge/lexers/nasm.rb index b413007d7c..5a5bb99a2f 100644 --- a/lib/rouge/lexers/nasm.rb +++ b/lib/rouge/lexers/nasm.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/nginx.rb b/lib/rouge/lexers/nginx.rb index ac361a7001..bc842d7602 100644 --- a/lib/rouge/lexers/nginx.rb +++ b/lib/rouge/lexers/nginx.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/nim.rb b/lib/rouge/lexers/nim.rb index 8a470df2a2..06f6f3b6a8 100644 --- a/lib/rouge/lexers/nim.rb +++ b/lib/rouge/lexers/nim.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/nix.rb b/lib/rouge/lexers/nix.rb index fb73aaa8b2..32505949d8 100644 --- a/lib/rouge/lexers/nix.rb +++ b/lib/rouge/lexers/nix.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/objective_c.rb b/lib/rouge/lexers/objective_c.rb index 5af1a5aa89..96ecf10765 100644 --- a/lib/rouge/lexers/objective_c.rb +++ b/lib/rouge/lexers/objective_c.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/ocaml.rb b/lib/rouge/lexers/ocaml.rb index f0f994711b..0284dae228 100644 --- a/lib/rouge/lexers/ocaml.rb +++ b/lib/rouge/lexers/ocaml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/pascal.rb b/lib/rouge/lexers/pascal.rb index 98f06cdab9..e6f4067be4 100644 --- a/lib/rouge/lexers/pascal.rb +++ b/lib/rouge/lexers/pascal.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/perl.rb b/lib/rouge/lexers/perl.rb index af0386fd2b..343d48c64c 100644 --- a/lib/rouge/lexers/perl.rb +++ b/lib/rouge/lexers/perl.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/php.rb b/lib/rouge/lexers/php.rb index 1585e63250..10061fa642 100644 --- a/lib/rouge/lexers/php.rb +++ b/lib/rouge/lexers/php.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/php/builtins.rb b/lib/rouge/lexers/php/builtins.rb index e4718a291a..d9db725156 100644 --- a/lib/rouge/lexers/php/builtins.rb +++ b/lib/rouge/lexers/php/builtins.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + # automatically generated by `rake builtins:php` module Rouge module Lexers diff --git a/lib/rouge/lexers/plain_text.rb b/lib/rouge/lexers/plain_text.rb index 016752d643..617076bc35 100644 --- a/lib/rouge/lexers/plain_text.rb +++ b/lib/rouge/lexers/plain_text.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/plist.rb b/lib/rouge/lexers/plist.rb index dfd8471288..a4c7557950 100644 --- a/lib/rouge/lexers/plist.rb +++ b/lib/rouge/lexers/plist.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Plist < RegexLexer diff --git a/lib/rouge/lexers/pony.rb b/lib/rouge/lexers/pony.rb index 6e7908d10b..3abd061df0 100644 --- a/lib/rouge/lexers/pony.rb +++ b/lib/rouge/lexers/pony.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/powershell.rb b/lib/rouge/lexers/powershell.rb index 48ff90ec06..6bee704d45 100644 --- a/lib/rouge/lexers/powershell.rb +++ b/lib/rouge/lexers/powershell.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/praat.rb b/lib/rouge/lexers/praat.rb index 5474834133..dc62c6e81c 100644 --- a/lib/rouge/lexers/praat.rb +++ b/lib/rouge/lexers/praat.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/prolog.rb b/lib/rouge/lexers/prolog.rb index 64d294940e..05cf9bbf99 100644 --- a/lib/rouge/lexers/prolog.rb +++ b/lib/rouge/lexers/prolog.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/prometheus.rb b/lib/rouge/lexers/prometheus.rb index 7409559f83..0bb1c33ca9 100644 --- a/lib/rouge/lexers/prometheus.rb +++ b/lib/rouge/lexers/prometheus.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Prometheus < RegexLexer diff --git a/lib/rouge/lexers/properties.rb b/lib/rouge/lexers/properties.rb index d6dddf01c3..8f876bfc86 100644 --- a/lib/rouge/lexers/properties.rb +++ b/lib/rouge/lexers/properties.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/protobuf.rb b/lib/rouge/lexers/protobuf.rb index a5e24dd346..9d8d753d6f 100644 --- a/lib/rouge/lexers/protobuf.rb +++ b/lib/rouge/lexers/protobuf.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/puppet.rb b/lib/rouge/lexers/puppet.rb index eabdbc3d12..ffbec26622 100644 --- a/lib/rouge/lexers/puppet.rb +++ b/lib/rouge/lexers/puppet.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/python.rb b/lib/rouge/lexers/python.rb index 987efa3da1..1f966f9eca 100644 --- a/lib/rouge/lexers/python.rb +++ b/lib/rouge/lexers/python.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/q.rb b/lib/rouge/lexers/q.rb index 196cac4b2f..ad18b8830b 100644 --- a/lib/rouge/lexers/q.rb +++ b/lib/rouge/lexers/q.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Q < RegexLexer diff --git a/lib/rouge/lexers/qml.rb b/lib/rouge/lexers/qml.rb index 51dbac78f5..c545de36b0 100644 --- a/lib/rouge/lexers/qml.rb +++ b/lib/rouge/lexers/qml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/r.rb b/lib/rouge/lexers/r.rb index d09070e085..423d7d9319 100644 --- a/lib/rouge/lexers/r.rb +++ b/lib/rouge/lexers/r.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/racket.rb b/lib/rouge/lexers/racket.rb index af9ff683eb..b4bd8f8761 100644 --- a/lib/rouge/lexers/racket.rb +++ b/lib/rouge/lexers/racket.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + module Rouge module Lexers class Racket < RegexLexer diff --git a/lib/rouge/lexers/ruby.rb b/lib/rouge/lexers/ruby.rb index 25beaa6beb..1f3291c206 100644 --- a/lib/rouge/lexers/ruby.rb +++ b/lib/rouge/lexers/ruby.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/rust.rb b/lib/rouge/lexers/rust.rb index e8c524eaf2..b9fd649d5d 100644 --- a/lib/rouge/lexers/rust.rb +++ b/lib/rouge/lexers/rust.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sass.rb b/lib/rouge/lexers/sass.rb index 7382fe8eca..44fbe82de3 100644 --- a/lib/rouge/lexers/sass.rb +++ b/lib/rouge/lexers/sass.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sass/common.rb b/lib/rouge/lexers/sass/common.rb index 25bb5461f3..27850dbefe 100644 --- a/lib/rouge/lexers/sass/common.rb +++ b/lib/rouge/lexers/sass/common.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/scala.rb b/lib/rouge/lexers/scala.rb index f8ba463be8..0b0e9a410c 100644 --- a/lib/rouge/lexers/scala.rb +++ b/lib/rouge/lexers/scala.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/scheme.rb b/lib/rouge/lexers/scheme.rb index 41baa321a6..5a856102f6 100644 --- a/lib/rouge/lexers/scheme.rb +++ b/lib/rouge/lexers/scheme.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/scss.rb b/lib/rouge/lexers/scss.rb index 35d160a067..4510a5f410 100644 --- a/lib/rouge/lexers/scss.rb +++ b/lib/rouge/lexers/scss.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sed.rb b/lib/rouge/lexers/sed.rb index 14bab41520..55eb1b9265 100644 --- a/lib/rouge/lexers/sed.rb +++ b/lib/rouge/lexers/sed.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/shell.rb b/lib/rouge/lexers/shell.rb index 3164095186..4b7d7d72a7 100644 --- a/lib/rouge/lexers/shell.rb +++ b/lib/rouge/lexers/shell.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sieve.rb b/lib/rouge/lexers/sieve.rb index 4b6528e1b0..a826f4d985 100644 --- a/lib/rouge/lexers/sieve.rb +++ b/lib/rouge/lexers/sieve.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/slim.rb b/lib/rouge/lexers/slim.rb index 6dea393453..f09ee3201e 100644 --- a/lib/rouge/lexers/slim.rb +++ b/lib/rouge/lexers/slim.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/smalltalk.rb b/lib/rouge/lexers/smalltalk.rb index 6f448c14d3..797a2c5c27 100644 --- a/lib/rouge/lexers/smalltalk.rb +++ b/lib/rouge/lexers/smalltalk.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/smarty.rb b/lib/rouge/lexers/smarty.rb index 58bf6df0be..e21b6e5011 100644 --- a/lib/rouge/lexers/smarty.rb +++ b/lib/rouge/lexers/smarty.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sml.rb b/lib/rouge/lexers/sml.rb index ce0ccdd91a..2755dc9501 100644 --- a/lib/rouge/lexers/sml.rb +++ b/lib/rouge/lexers/sml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/sql.rb b/lib/rouge/lexers/sql.rb index 23ec1cf827..60c15f4b97 100644 --- a/lib/rouge/lexers/sql.rb +++ b/lib/rouge/lexers/sql.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/swift.rb b/lib/rouge/lexers/swift.rb index b4d9cf8778..ca2fc29ef9 100644 --- a/lib/rouge/lexers/swift.rb +++ b/lib/rouge/lexers/swift.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/tap.rb b/lib/rouge/lexers/tap.rb index defb998c89..824c4fe73c 100644 --- a/lib/rouge/lexers/tap.rb +++ b/lib/rouge/lexers/tap.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Tap < RegexLexer diff --git a/lib/rouge/lexers/tcl.rb b/lib/rouge/lexers/tcl.rb index 77262aa430..60f84f853d 100644 --- a/lib/rouge/lexers/tcl.rb +++ b/lib/rouge/lexers/tcl.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/tex.rb b/lib/rouge/lexers/tex.rb index 6d358b3902..fa8f0a5a73 100644 --- a/lib/rouge/lexers/tex.rb +++ b/lib/rouge/lexers/tex.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/toml.rb b/lib/rouge/lexers/toml.rb index e0ee149ba8..40ecd7a6a4 100644 --- a/lib/rouge/lexers/toml.rb +++ b/lib/rouge/lexers/toml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/tsx.rb b/lib/rouge/lexers/tsx.rb index f917414532..043a526f23 100644 --- a/lib/rouge/lexers/tsx.rb +++ b/lib/rouge/lexers/tsx.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/tulip.rb b/lib/rouge/lexers/tulip.rb index a6a3ac5aa4..e26376b6b3 100644 --- a/lib/rouge/lexers/tulip.rb +++ b/lib/rouge/lexers/tulip.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers class Tulip < RegexLexer diff --git a/lib/rouge/lexers/turtle.rb b/lib/rouge/lexers/turtle.rb index 33da7afb82..505086f4a6 100644 --- a/lib/rouge/lexers/turtle.rb +++ b/lib/rouge/lexers/turtle.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/twig.rb b/lib/rouge/lexers/twig.rb index 7eb61989a9..ad2d61a061 100644 --- a/lib/rouge/lexers/twig.rb +++ b/lib/rouge/lexers/twig.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/typescript.rb b/lib/rouge/lexers/typescript.rb index 71dfd11c33..353ca7ffd5 100644 --- a/lib/rouge/lexers/typescript.rb +++ b/lib/rouge/lexers/typescript.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/typescript/common.rb b/lib/rouge/lexers/typescript/common.rb index 7a3c37618d..7d161ff05f 100644 --- a/lib/rouge/lexers/typescript/common.rb +++ b/lib/rouge/lexers/typescript/common.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/vala.rb b/lib/rouge/lexers/vala.rb index 81a605ff4c..29101e4c13 100644 --- a/lib/rouge/lexers/vala.rb +++ b/lib/rouge/lexers/vala.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/vb.rb b/lib/rouge/lexers/vb.rb index b7f3d5f983..406465ad8d 100644 --- a/lib/rouge/lexers/vb.rb +++ b/lib/rouge/lexers/vb.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/verilog.rb b/lib/rouge/lexers/verilog.rb index 522f6d2079..812b8fae9a 100644 --- a/lib/rouge/lexers/verilog.rb +++ b/lib/rouge/lexers/verilog.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/vhdl.rb b/lib/rouge/lexers/vhdl.rb index 4b14c2831c..4255632ea3 100644 --- a/lib/rouge/lexers/vhdl.rb +++ b/lib/rouge/lexers/vhdl.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/viml.rb b/lib/rouge/lexers/viml.rb index 109e2cf28c..363ff9782a 100644 --- a/lib/rouge/lexers/viml.rb +++ b/lib/rouge/lexers/viml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/vue.rb b/lib/rouge/lexers/vue.rb index 2a3b35fad4..59bd664cd8 100644 --- a/lib/rouge/lexers/vue.rb +++ b/lib/rouge/lexers/vue.rb @@ -1,3 +1,5 @@ +# frozen_string_literal: true + module Rouge module Lexers load_lexer 'html.rb' diff --git a/lib/rouge/lexers/wollok.rb b/lib/rouge/lexers/wollok.rb index a8012fff59..c46960c9be 100644 --- a/lib/rouge/lexers/wollok.rb +++ b/lib/rouge/lexers/wollok.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/xml.rb b/lib/rouge/lexers/xml.rb index 0773acddb4..0b95b3709c 100644 --- a/lib/rouge/lexers/xml.rb +++ b/lib/rouge/lexers/xml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/lexers/yaml.rb b/lib/rouge/lexers/yaml.rb index 6d6a8b808a..4afb31c55a 100644 --- a/lib/rouge/lexers/yaml.rb +++ b/lib/rouge/lexers/yaml.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Lexers diff --git a/lib/rouge/plugins/redcarpet.rb b/lib/rouge/plugins/redcarpet.rb index 4ae513bc13..e70bd34a52 100644 --- a/lib/rouge/plugins/redcarpet.rb +++ b/lib/rouge/plugins/redcarpet.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # this file is not require'd from the root. To use this plugin, run: # diff --git a/lib/rouge/regex_lexer.rb b/lib/rouge/regex_lexer.rb index 774530e98f..f1a0d0d3e5 100644 --- a/lib/rouge/regex_lexer.rb +++ b/lib/rouge/regex_lexer.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge # @abstract diff --git a/lib/rouge/template_lexer.rb b/lib/rouge/template_lexer.rb index 8e063a84f5..384b37b359 100644 --- a/lib/rouge/template_lexer.rb +++ b/lib/rouge/template_lexer.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge # @abstract diff --git a/lib/rouge/text_analyzer.rb b/lib/rouge/text_analyzer.rb index 834a0b11c2..0540ca4252 100644 --- a/lib/rouge/text_analyzer.rb +++ b/lib/rouge/text_analyzer.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge class TextAnalyzer < String diff --git a/lib/rouge/theme.rb b/lib/rouge/theme.rb index be07425a0a..731da002b0 100644 --- a/lib/rouge/theme.rb +++ b/lib/rouge/theme.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge class Theme diff --git a/lib/rouge/themes/base16.rb b/lib/rouge/themes/base16.rb index 9fea1c8add..bf62fa7211 100644 --- a/lib/rouge/themes/base16.rb +++ b/lib/rouge/themes/base16.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/colorful.rb b/lib/rouge/themes/colorful.rb index b108fe6e14..b2de856acf 100644 --- a/lib/rouge/themes/colorful.rb +++ b/lib/rouge/themes/colorful.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/github.rb b/lib/rouge/themes/github.rb index bc875a8474..de1c31e10f 100644 --- a/lib/rouge/themes/github.rb +++ b/lib/rouge/themes/github.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/gruvbox.rb b/lib/rouge/themes/gruvbox.rb index 330803de67..25cd123a0b 100644 --- a/lib/rouge/themes/gruvbox.rb +++ b/lib/rouge/themes/gruvbox.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true # TODO how are we going to handle soft/hard contrast? diff --git a/lib/rouge/themes/igor_pro.rb b/lib/rouge/themes/igor_pro.rb index a75a4cdcf7..adc53a2506 100644 --- a/lib/rouge/themes/igor_pro.rb +++ b/lib/rouge/themes/igor_pro.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/molokai.rb b/lib/rouge/themes/molokai.rb index 6f14aa78df..119422f29c 100644 --- a/lib/rouge/themes/molokai.rb +++ b/lib/rouge/themes/molokai.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/monokai.rb b/lib/rouge/themes/monokai.rb index 3273f7d7ac..e230d609b9 100644 --- a/lib/rouge/themes/monokai.rb +++ b/lib/rouge/themes/monokai.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/monokai_sublime.rb b/lib/rouge/themes/monokai_sublime.rb index 5c700e79a5..bbecbf3f2d 100644 --- a/lib/rouge/themes/monokai_sublime.rb +++ b/lib/rouge/themes/monokai_sublime.rb @@ -1,4 +1,6 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true + module Rouge module Themes class MonokaiSublime < CSSTheme diff --git a/lib/rouge/themes/pastie.rb b/lib/rouge/themes/pastie.rb index e8d9b6acdc..c297d163e1 100644 --- a/lib/rouge/themes/pastie.rb +++ b/lib/rouge/themes/pastie.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/thankful_eyes.rb b/lib/rouge/themes/thankful_eyes.rb index dcb9aedb84..f0b5aa77fe 100644 --- a/lib/rouge/themes/thankful_eyes.rb +++ b/lib/rouge/themes/thankful_eyes.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/themes/tulip.rb b/lib/rouge/themes/tulip.rb index 938f65e175..90e0c7fb93 100644 --- a/lib/rouge/themes/tulip.rb +++ b/lib/rouge/themes/tulip.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge module Themes diff --git a/lib/rouge/token.rb b/lib/rouge/token.rb index ce044a7718..110b054703 100644 --- a/lib/rouge/token.rb +++ b/lib/rouge/token.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge class Token diff --git a/lib/rouge/util.rb b/lib/rouge/util.rb index 0c1f93a341..124cda8e96 100644 --- a/lib/rouge/util.rb +++ b/lib/rouge/util.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge class InheritableHash < Hash diff --git a/lib/rouge/version.rb b/lib/rouge/version.rb index 0d7997ad4f..02429d7d40 100644 --- a/lib/rouge/version.rb +++ b/lib/rouge/version.rb @@ -1,4 +1,5 @@ # -*- coding: utf-8 -*- # +# frozen_string_literal: true module Rouge def self.version diff --git a/tasks/gherkin.rake b/tasks/gherkin.rake index f9a25ad357..a1cbc5d88e 100644 --- a/tasks/gherkin.rake +++ b/tasks/gherkin.rake @@ -28,6 +28,8 @@ module GherkinKeywords def source(&b) yield '# -*- coding: utf-8 -*- #' + yield '# frozen_string_literal: true' + yield '' yield '# automatically generated by `rake builtins:gherkin`' yield 'module Rouge' yield ' module Lexers' diff --git a/tasks/lua.rake b/tasks/lua.rake index 8c9162e965..bf80951d7e 100644 --- a/tasks/lua.rake +++ b/tasks/lua.rake @@ -4,6 +4,8 @@ require 'open-uri' def lua_builtins_source(lua_functions) yield "# -*- coding: utf-8 -*- #" + yield "# frozen_string_literal: true" + yield "" yield "# automatically generated by `rake builtins:lua`" yield "module Rouge" yield " module Lexers" diff --git a/tasks/matlab.rake b/tasks/matlab.rake index 94f133c32a..1363d28571 100644 --- a/tasks/matlab.rake +++ b/tasks/matlab.rake @@ -19,6 +19,8 @@ end def matlab_builtins_source yield "# -*- coding: utf-8 -*- #" + yield "# frozen_string_literal: true" + yield "" yield "# automatically generated by `rake builtins:matlab`" yield "module Rouge" yield " module Lexers" diff --git a/tasks/php.rake b/tasks/php.rake index 9005418f8c..111cf2dfdb 100644 --- a/tasks/php.rake +++ b/tasks/php.rake @@ -31,6 +31,8 @@ end def php_builtins_source yield "# -*- coding: utf-8 -*- #" + yield "# frozen_string_literal: true" + yield "" yield "# automatically generated by `rake builtins:php`" yield "module Rouge" yield " module Lexers" diff --git a/tasks/vim.rake b/tasks/vim.rake index 2aea1264f4..b4cbaf4e7c 100644 --- a/tasks/vim.rake +++ b/tasks/vim.rake @@ -33,6 +33,8 @@ def render_keywords(keywords, &b) return enum_for(:render_keywords, keywords).to_a.join("\n") unless b yield '# encoding: utf-8' + yield '# frozen_string_literal: true' + yield '' yield '# DO NOT EDIT: automatically generated by `rake builtins:vim`.' yield '# see tasks/vim.rake for more info.' yield 'module Rouge'