module ErrorMessages

ErrorMessages module contains different error messages

Public Instance Methods

arg_err_build(exp, got) click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 11
def arg_err_build(exp, got)
  'Incorrect number of arguments, expected ' + exp.to_s + ' got ' + got.to_s
end
no_procedure_build(name) click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 15
def no_procedure_build(name)
  name.to_s + ' is not function'
end
type_err(exp, got) click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 23
def type_err(exp, got)
  'Invalid data type, expected ' + exp.to_s + ' got ' + got.to_s
end
unbalanced_brackets_error() click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 3
def unbalanced_brackets_error
  'error signaled: unbalanced brackets'
end
unbalanced_quotes_error() click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 7
def unbalanced_quotes_error
  'error signaled: unbalanced quotes'
end
unbound_symbol_err(symbol) click to toggle source
# File lib/lisp/interpreter/core/errors.rb, line 19
def unbound_symbol_err(symbol)
  'Unbound symbol ' + symbol.to_s
end