Class: ERBLint::Linters::ParserErrors
- Inherits:
-
ERBLint::Linter
- Object
- ERBLint::Linter
- ERBLint::Linters::ParserErrors
- Includes:
- ERBLint::LinterRegistry
- Defined in:
- lib/erb_lint/linters/parser_errors.rb
Constant Summary
Constants included from ERBLint::LinterRegistry
ERBLint::LinterRegistry::CUSTOM_LINTERS_DIR, ERBLint::LinterRegistry::DEPRECATED_CUSTOM_LINTERS_DIR
Instance Attribute Summary
Attributes inherited from ERBLint::Linter
Instance Method Summary collapse
Methods included from ERBLint::LinterRegistry
clear, find_by_name, included, linters, load_custom_linters
Methods inherited from ERBLint::Linter
#add_offense, #clear_offenses, #enabled?, #excludes_file?, inherited, #initialize, #run_and_update_offense_status, support_autocorrect?
Constructor Details
This class inherits a constructor from ERBLint::Linter
Instance Method Details
#run(processed_source) ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'lib/erb_lint/linters/parser_errors.rb', line 8 def run(processed_source) processed_source.parser.parser_errors.each do |error| add_offense( error.loc, "#{error.} (at #{error.loc.source})", ) end end |