class RuboCop::AST::NodePattern::Node::Sequence

Node class for `(type first second …)`

Public Class Methods

new(type, children = [], properties = {}) click to toggle source
Calls superclass method
# File lib/rubocop/ast/node_pattern/node.rb, line 117
def initialize(type, children = [], properties = {})
  if (replace = children.first.in_sequence_head)
    children = [*replace, *children[1..-1]]
  end

  super
end