Class: Rubocop::Cop::Style::SpaceInsideBrackets

Inherits:
Cop
  • Object
show all
Includes:
SpaceInside
Defined in:
lib/rubocop/cop/style/surrounding_space.rb

Overview

Checks for spaces inside square brackets.

Constant Summary

Constants included from SpaceInside

Rubocop::Cop::Style::SpaceInside::MSG

Instance Attribute Summary

Attributes inherited from Cop

#autocorrect, #debug, #disabled_lines, #offences

Instance Method Summary collapse

Methods included from SpaceInside

#inspect

Methods included from SurroundingSpace

#build_token_table, #index_of_first_token, #index_of_last_token, #space_between?

Methods inherited from Cop

#add_offence, #autocorrect_action, cop_name, cop_type, #do_autocorrect, #ignore_node, inherited, #initialize, #inspect, lint?, #name, rails?, style?

Constructor Details

This class inherits a constructor from Rubocop::Cop::Cop

Instance Method Details

#specificsObject



254
255
256
# File 'lib/rubocop/cop/style/surrounding_space.rb', line 254

def specifics
  [:tLBRACK, :tRBRACK, 'square brackets']
end