Class: Nendo::Nil

Inherits:
Object
  • Object
show all
Includes:
Enumerable
Defined in:
lib/nendo.rb

Instance Method Summary collapse

Instance Method Details

#carObject



56
57
58
# File 'lib/nendo.rb', line 56

def car()
  raise "Error: Nil#car method:  pair required, but got ()"
end

#cdrObject



59
60
61
# File 'lib/nendo.rb', line 59

def cdr()
  raise "Error: Nil#cdr method:  pair required, but got ()"
end

#eachObject



46
# File 'lib/nendo.rb', line 46

def each()               end

#getLastAtomObject

Raises:

  • (RuntimeError)


52
53
54
# File 'lib/nendo.rb', line 52

def getLastAtom() 
  raise RuntimeError, "Error: Nil#getLastAtom method:  this cell is not dotted list."
end

#isDottedObject



50
# File 'lib/nendo.rb', line 50

def isDotted()  false    end

#isNullObject



49
# File 'lib/nendo.rb', line 49

def isNull()    true     end

#lastAtomObject



51
# File 'lib/nendo.rb', line 51

def lastAtom()  false    end

#lengthObject



48
# File 'lib/nendo.rb', line 48

def length()    0        end

#to_arrObject



47
# File 'lib/nendo.rb', line 47

def to_arr()    []       end

#to_sObject



55
# File 'lib/nendo.rb', line 55

def to_s()      ""       end