class Regexp::Expression::CharacterSet::Range

Public Instance Methods

<<(exp) click to toggle source
Calls superclass method Regexp::Expression::Subexpression#<<
# File lib/regexp_parser/expression/classes/character_set/range.rb, line 8
def <<(exp)
  complete? and raise Regexp::Parser::Error,
    "Can't add more than 2 expressions to a Range"
  super
end
complete?() click to toggle source
# File lib/regexp_parser/expression/classes/character_set/range.rb, line 14
def complete?
  count == 2
end
ts() click to toggle source
# File lib/regexp_parser/expression/classes/character_set/range.rb, line 4
def ts
  (head = expressions.first) ? head.ts : @ts
end