Sha256: d4555d53f773d98cf250ef0b796b67b3805a69e40face639eaf09c6cf838e036
Contents?: true
Size: 847 Bytes
Versions: 4
Compression:
Stored size: 847 Bytes
Contents
module Reek module Cli module Report # # Formats the location of a warning as an empty string. # module BlankLocationFormatter def self.format(_warning) '' end end # # Formats the location of a warning as an array of line numbers. # module DefaultLocationFormatter def self.format(warning) "#{warning.lines.inspect}:" end end # # Formats the location of a warning as a combination of source file name # and line number. In this format, it is not possible to show more than # one line number, so the first number is displayed. # module SingleLineLocationFormatter def self.format(warning) "#{warning.source}:#{warning.lines.first}: " end end end end end
Version data entries
4 entries across 4 versions & 1 rubygems