Module: Reek::Report::SingleLineLocationFormatter Private

Defined in:
lib/reek/report/location_formatter.rb

Overview

This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.

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.

Class Method Summary collapse

Class Method Details

.format(warning) ⇒ Object

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.



30
31
32
# File 'lib/reek/report/location_formatter.rb', line 30

def self.format(warning)
  "#{warning.source}:#{warning.lines.first}: "
end