Class: RParsec::Token

Inherits:
Object
  • Object
show all
Defined in:
lib/rparsec/token.rb

Instance Method Summary collapse

Instance Method Details

#lengthObject

The length of the token.



18
# File 'lib/rparsec/token.rb', line 18

def length = @text.length

#to_sObject

String representation of the token.



23
# File 'lib/rparsec/token.rb', line 23

def to_s = "#{@kind}: #{@text}"