Class: LibRubyParser::Nodes::MatchPatternP

Inherits:
LibRubyParser::Node show all
Defined in:
lib/lib-ruby-parser/nodes.rb

Overview

Represents a one-line pattern matching that never throws but returns true/false (i.e. foo in pattern)

Instance Attribute Summary collapse

Instance Attribute Details

#expression_lLoc (readonly)

Location of the full expression

foo in pattern
~~~~~~~~~~~~~~

Returns:



2765
2766
2767
# File 'lib/lib-ruby-parser/nodes.rb', line 2765

def expression_l
  @expression_l
end

#operator_lLoc (readonly)

Location of the in operator

foo in pattern
    ~~

Returns:



2756
2757
2758
# File 'lib/lib-ruby-parser/nodes.rb', line 2756

def operator_l
  @operator_l
end

#patternNode (readonly)

Pattern that is used for matching

Returns:



2747
2748
2749
# File 'lib/lib-ruby-parser/nodes.rb', line 2747

def pattern
  @pattern
end

#valueNode (readonly)

Value that is used for matching

Returns:



2743
2744
2745
# File 'lib/lib-ruby-parser/nodes.rb', line 2743

def value
  @value
end