class RuboCop::AST::WhileNode

to all ‘while` nodes within RuboCop.
node when the builder constructs the AST, making its methods available
A node extension for `while` nodes. This will be used in place of a plain

def do?

Returns:
  • (Boolean) - whether the `until` node has a `do` keyword
def do?
  loc_is?(:begin, 'do')
end

def inverse_keyword

Returns:
  • (String) - the inverse keyword of the `while` statement
def inverse_keyword
  'until'
end

def keyword

Returns:
  • (String) - the keyword of the `while` statement
def keyword
  'while'
end