Module: RuboCop::AST::Sexp

Included in:
Node, Cop::Cop, Cop::Cop, Cop::Lint::DeprecatedClassMethods::DeprecatedClassMethod, Cop::Util
Defined in:
lib/rubocop/ast/sexp.rb

Overview

This module provides a shorthand method to create a Node like ‘Parser::AST::Sexp`.

Instance Method Summary collapse

Instance Method Details

#s(type, *children) ⇒ Object

Creates a Node with type ‘type` and children `children`.



11
12
13
# File 'lib/rubocop/ast/sexp.rb', line 11

def s(type, *children)
  Node.new(type, children)
end