Class: Wool::MisalignedUnindentationWarning
- Inherits:
-
LineWarning
- Object
- Struct
- Warning
- LineWarning
- Wool::MisalignedUnindentationWarning
- Defined in:
- lib/wool/warnings/misaligned_unindentation.rb
Overview
This warning is used when
Instance Attribute Summary
Attributes inherited from Warning
#body, #file, #line_number, #name, #settings, #severity
Instance Method Summary collapse
- #fix ⇒ Object
-
#initialize(file, line, expectation) ⇒ MisalignedUnindentationWarning
constructor
A new instance of MisalignedUnindentationWarning.
Methods inherited from LineWarning
Methods inherited from Warning
all_types, all_warnings, concrete_warnings, #count_occurrences, #desc, #fixable?, #generated_warnings, #get_indent, #indent, inherited, #match?, opt, options, setting_accessor, type
Methods included from Advice
#advice_counter, #after_advice, #argument_advice, #before_advice, #bump_advice_counter!, #with_advice
Methods included from ModuleExtensions
#attr_accessor_with_default, #cattr_accessor, #cattr_accessor_with_default, #cattr_get_and_setter, #cattr_reader, #cattr_writer
Methods included from SexpAnalysis
Methods included from LexicalAnalysis
#find_keyword, #find_token, #lex, #select_token, #split_on_keyword, #split_on_token, #text_between_token_positions
Constructor Details
#initialize(file, line, expectation) ⇒ MisalignedUnindentationWarning
Returns a new instance of MisalignedUnindentationWarning.
8 9 10 11 |
# File 'lib/wool/warnings/misaligned_unindentation.rb', line 8 def initialize(file, line, expectation) super(file, line) @expectation = expectation end |
Instance Method Details
#fix ⇒ Object
13 14 15 |
# File 'lib/wool/warnings/misaligned_unindentation.rb', line 13 def fix indent self.line, @expectation end |