Class: Fast::Maybe

Inherits:
Find
  • Object
show all
Defined in:
lib/fast.rb

Overview

True if the node does not exist When exists, it should match.

Instance Attribute Summary

Attributes inherited from Find

#token

Instance Method Summary collapse

Methods inherited from Find

#==, #compare_symbol_or_head, #debug, #debug_match_recursive, #initialize, #match_recursive, #to_s

Constructor Details

This class inherits a constructor from Fast::Find

Instance Method Details

#match?(node) ⇒ Boolean

Returns:

  • (Boolean)


697
698
699
# File 'lib/fast.rb', line 697

def match?(node)
  node.nil? || super
end