List of error messages

This page gives a list of all the error messages, in alphabetical order, with an explanation of the message, and if appropriate an example that would generate the error. Where possible it also includes suggestions of how to fix the error.

This page applies to Version 2.8 of uLisp and later. For information about the error messages in earlier versions of uLisp see: Error messages pre Release 2.8.

20th February 2026: Updated this list to match the error messages now in uLisp 4.9, and improved the layout.

Layout of error messages

For details of the error message format see Error message format.

Alphabetical list of error messages

The following list gives the possible error messages, in alphabetical order.

A

already being traced

The specified function is already being traced by the trace command.

already connected

Unable to connect to the network specified to wifi-connect because you are already connected.

already tracing … functions

The trace command was given when the maximum number of functions is already being traced.

argument is not a bit value

The argument to a bit array is not 0 or 1. For example:

> (defvar a (make-array 10 :element-type 'bit :initial-element 0))
> (setf (aref a 4) 2)
Error: 'setf' argument is not a bit value: 2

argument is not a character

The argument to char-code is not a character. For example:

(char-code "a")

argument is not an integer

The argument to a function expecting an integer is not an integer. For example:

> (nth 2.0 '(a b c))
Error: 'nth' argument is not an integer: 2.0

argument is not a keyword

The argument is not a keyword when one was expected.

argument is not a list

The argument to a function expecting a list is not a list. For example:

> (append "cat" "dog")
Error: 'append' argument is not a list: "cat"

Or, in format the argument for a ~{ directive is not a list.

argument is not a list or string

The argument to subseq must be a list or string.

argument is not a list, 1d array, or string

The argument to length must be a list, one-dimensional array, or string. For example:

> (let ((a 12345)) (print (length a)))
Error: 'length' argument is not a list or string: 12345

argument is not a number

The argument to a numeric function was not an integer or floating-point number. For example:

> (abs "Hello")
Error: 'abs' argument is not a number: "Hello"

argument is not a proper list

The argument to a function expecting a list must be a list not containing a dotted pair. For example:

> (append '(a . b) '(c d e))
Error: 'append' argument is not a proper list: (a . b)

argument is not a string

The argument to a function expecting a string is not a string. For example:

> (read-from-string 123)
Error: 'read-from-string' argument is not a string: 123

argument is not a symbol

The argument to a function expecting a symbol is not a symbol. For example:

> (require 3)
Error: 'require' argument is not a symbol: 3

argument is not an array

The argument to array-dimensions must be an array.

argument not recognised

The keyword argument to make-array must be :initial-element or :element-type.

arguments are not both lists or strings

Both arguments to search must be lists or strings. For example:

> (search #\c "alphabetical")
Error: 'search' arguments are not both lists or strings

If you want to search for a character in a string, first convert it to a string:

> (search (string #\c) "alphabetical")
9

arithmetic overflow

On a 16-bit platform overflow occurred in an expression. For example:

> (setq a -32768)
> (decf a)

autorun not available

On this platform autorunning a function after load-image is not supported.

C

can't be used as a function

The symbol can't be used as a function. For example:

> (&rest 2)
Error: '&rest' can't be used as a function

can't convert to string

The string function was called with an argument that wasn't a symbol or character. For example:

> (string 3)
Error: 'string' can't convert to string: 3

can't evaluate a dotted pair

An attempt was made to evaluate a dotted pair. For example:

> (print . 3)
Error: Can't evaluate a dotted pair: 3

can't evaluate CODE header

A form defined with defcode cannot be evaluated.

can't nest ~{

In format uLisp currently only supports one level of ~{~}.

can't take car

The argument to car is not a list. For example:

> (car 12)
Error: Can't take car: 12

can't take cdr

The argument to cdr is not a list. For example:

> (cdr 12)
Error: Can't take cdr: 12

connection failed

Unable to connect to the network specified to wifi-connect.

D

dimension can't be negative

An array dimension can't be negative. For example:

> (defvar a (make-array -10))
Error: 'make-array' dimension can't be negative

dimensions can't be nil

In uLisp the array dimensions can't be nil. For example:

> (defvar a (make-array nil))
Error: 'make-array' dimensions can't be nil

division by zero

Attempt to divide by zero. For example:

> (/ 2.0 0)
Error: '/' division by zero

E

element is not a list

Each element in the second argument to assoc must be a cons or a list. For example:

> (assoc 'a '((b . 2) c))
Error: 'assoc' element is not a list: c

error in print

Trying to print something that can't be printed.

escape!

The escape character '~' was typed.

F

filename is not a string

The filename given to with-sd-card is not a string.

first argument is not an array

The first argument to aref is not a valid array. For example:

> (aref "hello")
Error: 'aref' first argument is not an array: "hello"

flash erase failed

A call to save-image failed to erase the stm32 flash.

flash write failed

A call to save-image failed to write to the stm32 flash.

function has too few arguments

A function supplied to funcall, apply, mapc, mapcar, mapcan, or sort has been called with fewer arguments than it was defined with. For example:

> (funcall mod 2)
Error: function has too few arguments

function has too many arguments

A function supplied to funcallapplymapcmapcarmapcan, or sort has been called with more arguments than it was defined with. For example:

> (funcall abs 2 3)
Error: function has too many arguments

H

has too few arguments

A function has been called with fewer arguments than it was defined with. For example:

> (defun sq (x) (* x x))
> (sq)
Error: 'sq' has too few arguments

has too many arguments

A function has been called with more arguments than it was defined with. For example:

> (defun sq (x) (* x x))
> (sq 2 3)
Error: 'sq' has too many arguments

I

illegal argument

Invalid argument to save-image. For example:

(save-image 23)

illegal character after #

In uLisp the only valid sequences are #', #*, #., #\, #(, #nA, #|, #b, #o, or #x.

illegal character in bit array

A bit array being defined with #* contains a character other than 0 or 1. For example:

> #*1010102
Error: illegal character in bit array

illegal clause

The arguments to case or cond included an illegal clause.

illegal entry

The arguments to defcode should be a symbol, integer, or list of integers.

illegal function

The specified function is illegal. For example:

> (nil 2)
Error: illegal function: nil

illegal function parameter

The &optional parameter in defun, lambda, or bind is invalid. For example:

> (bind (a &optional 3) '(1 2) b)
Error: 'bind' illegal function parameter: 3
 

illegal IP address

The IP address specified is not in a valid format.

illegal name

The argument is not a legal symbol name.

illegal optional parameter

The &optional parameter in defun, lambda, or bind is not a symbol. For example:

> (defun sq (x &optional (2 3)) (* x x))
> (sq 2)
Error: 'sq' illegal optional parameter: 2

illegal place

The in-place operations setf, incfdecf, push, and pop can only take the functions car, firstcdr, restnth, and aref in their second argument. For example:

> (defvar a '(1 2 3 4))
> (setf (second a) 7)
Error: 'setf' illegal place

The solution is to rewrite the second argument in terms of these functions:

(setf (car (cdr a)) 7)

image size too large

The size of the workspace is larger than the available non-volatile storage.

image too large by …

The size of the workspace is larger than the available space in LittleFS.

incomplete list

A close bracket was typed with no matching opening bracket.

incorrect number of arguments

A call to with-spi must have five arguments.

index can't be negative

The index argument to nth or subseq can't be negative. For example:

> (subseq "ulisp" -1 2)
Error: 'subseq' index can't be negative: -1

index out of range

The index argument to char or subseq is outside the range of the characters in the string. For example:

> (char "cat" 3)
Error: 'char' index out of range

index to nth is out of range

In a reference to nth in setfincf, or decfpush, or pop the index is out of range. For example:

> (incf (nth 3 '(1 2 3)))
Error: 'incf' index to nth is out of range

initial contents don't match array type

An array definition is incorrect. For example:

> #2A((1 2) (3 4) (5))
Error: initial contents don't match array type

invalid argument

The argument to saveimage, loadimage, or length is not a list or string.

invalid default value

A default value was supplied without the &optional keyword in defun, lambda, or bind. For example:

> (defun sq (x (y 3)) (* x y))
> (sq 2)
Error: 'sq' invalid default value: (y 3)

invalid directive

In format the directive is either invalid or not supported by uLisp.

invalid keyword

The keyword is not valid for this function. For example:

> (pinmode 13 :high)
Error: 'pinmode' invalid keyword: :high

invalid pin

The analogreadanalogwrite, or note function is not supported on the specified pin.

invalid result

The arguments to expt give an invalid result. For example:

> (expt -1 .3)
Error: 'expt' invalid result

analogreadanalogwrite, or note function is not supported on the specified pin.

invalid stream

The stream is not a valid type of stream, or the stream has been closed. For example:

> (let (a) (with-output-to-string (str) (setq a str)) (print "goodbye" a))
Error: 'print' invalid stream

K

keyword argument not supported for strings

In search the :test argument is only supported for lists.

M

malformed list

The list is not a valid dotted list because more than one object follows a dot. For example:

> (a . b c)
Error: Malformed list

missing argument

The special forms unlesswhen, dolist, and dotimes must be followed by at least one argument. For example:

> (when)
Error: 'when' missing argument

Or, in format the argument for a directive is missing.

missing argument(s)

if must be followed by at least two arguments. For example:

> (if (print 3))
Error: 'if' missing argument(s)

missing stream argument

The stream argument is missing from a with-spi, with-sdcard, with-i2c, or with-serial form.

more than 4 parameters

Functions defined with defcode can have a maximum of four parameters.

N

network not found

The network specified to wifi-connect was not found.

no DataFlash found

The save-image, load-image, or autorun function failed because no DataFlash could be found.

no filename specified

A filename was not specified for with-sd-card.

no matching ~{

In format~} directive has been encountered without an opening ~{.

no room

There is no space left in the Lisp workspace. Delete some functions or variables using makunbound.

no room for string

A string supplied to with-client, wifi-softap, or wifi-connect is longer than the maximum number of characters. Access points are limited to 32 characters and passwords to 64 characters.

no saved image

No saved image was found when giving the loadimage command.

not a builtin

The function is not a built-in function.

not available

The save-image or load-image function is not available on this platform, or SD card support has not been enabled.

not a stream

The argument to a stream function is not a stream. For example:

> (let ((b 1)) (print "hello" b))
Error: 'print' not a stream: 1

not a symbol

The argument to defvardefun, or defcode is not a valid symbol.

not an i2c stream

The stream supplied to restart-i2c is not an I2C stream.

not enough room

LittleFS doesn't have enough room to save the image.

not enough room for code

There is not enough room for the machine-code function being defined with defcode. Either delete another function with makunbound to make room, or increase the value of:

#define CODESIZE

for the platform,

not supported

SD card support is not available.

not tracing

The untrace command specified a function that wasn't being traced with trace.

not valid here

The first item in a list is not a valid function. For example:

> ('a 2 3)
Error: not valid here: (quote a)

number out of range

A number has been entered that is out of range for the platform. For example:

(print 40000)

O

octave out of range

The octave specified for the note function is out of range for the PWM output.

odd number of arguments

The special forms setq, setf, and set should have an even number of arguments.

only supports strings

In uLisp concatenate only supports strings. For example:

> (concatenate 'list '(a b c) '(d e f))
Error: 'concatenate' only supports strings

P

port not supported

The port is not supported on this platform.

problem autorunning from LittleFS

No image was found when autorunning from LittleFS.

problem autorunning from SD card

The file ULISP.IMG was not found when autorunning from an SD card.

problem loading from LittleFS

There was a problem loading a saved image from LittleFS.

problem loading from SD card

There was a problem loading a saved image from the SD card. For example, the image was not found.

problem mounting LittleFS

LittleFS couldn't be initialised; for example, it wasn't selected in the Board options when uploading uLisp.

problem reading from SD card

There was a problem reading from the SD card with the directory command.

problem reading from SD card or invalid filename

There was a problem reading from the SD card. For example, the filename was longer than 8 characters or the file was not found.

problem saving to SD card

There was a problem saving an image to the SD card. For example, the SD card has been removed.

problem saving to LittleFS

There was a problem saving an image to LittleFS.

problem saving to LittleFS or invalid filename

There was a problem saving the image to LittleFS. For example, the filename was longer than 8 characters.

problem writing to SD card or invalid filename

There was a problem writing to the SD card. For example, the filename was longer than 8 characters or the SD card has been removed.

Q

quote not valid

In format a quote can only appear after a comma.

R

result is not a bit value

The special form incf or decf is being applied to a bit array, but the result is not 0 or 1.

result is not a proper list

The result being constructed by mapcan is not a proper list. For example:

> (mapcan (lambda (x) x) '((a b) (c . d) (e f)))
Error: 'mapcan' argument is not a proper list: (c . d)

S

save-image not available

On this platform save-image is not supported.

second argument is not a proper list

The second argument to mapcmapcar, or mapcan is not a proper list. For example:

> (mapc print "cat")
Error: 'mapc' second argument is not a proper list: "cat"

second argument to nth is not a list

In a reference to nth in setf, incf, or decf, the second argument is not a list. For example:

> (incf (nth 2 "cat"))
Error: 'incf' second argument to nth is not a list: "cat"

stack overflow

The Lisp stack has overflowed. On platforms with stack overflow detection it may be necessary to adjust the value of:

#define STACKDIFF

stream already in use

Only one string output stream can be used at a time. For example:

> (with-output-to-string (s1) (with-output-to-string (s2) (print "hello" s2)))
Error: 'with-output-to-string' stream already in use

subscript out of range

The subscript to an array exceeds the size of the corresponding dimension. For example:

> (defvar a (make-array '(4 4)))
> (aref a 2 4)
Error: 'aref' subscript out of range: 4

T

third argument is not a proper list

The third argument to mapc, mapcar, or mapcan is not a proper list. For example:

> (mapcan list '(a b c) '(d e . f))
Error: 'mapcan' third argument is not a proper list: (d e . f)

too few arguments

A function is being called with fewer arguments than it expects. For example:

> (mod 2)
Error: 'mod' too few arguments

too many arguments

A function is being called with more arguments than it expects. For example:

> (expt 2 3 4)
Error: 'expt' too many arguments

too many long symbols

uLisp is restricted to 1535 long symbols.

too few subscripts

An array element doesn't specify enough subscripts. For example:

> (defvar a (make-array '(4 4)))
> (aref a 2)
Error: 'aref' too few subscripts

too many subscripts

An array element specifies too many subscripts. For example:

> (defvar a (make-array '(4 4)))
> (aref a 2 2 2)
Error: 'aref' too many subscripts

U

unable to connect

Unable to connect to the network specified to wifi-connect.

undefined

A symbol has been evaluated that has not yet been defined. For example:

> a
Error: undefined: a

unknown character

The escape sequence #\ is followed by an unknown character. For example:

#\FRED

unknown stream type

The stream type is unknown.

unknown variable

A symbol has been referenced that has not yet been defined. For example:

> (setq a 23)
Error: unknown variable: a

unmatched right bracket

A right bracket was typed with no matching left bracket.

unpaired keyword

The keyword in assoc, member, or search must be followed by a value. For example:

> (assoc 'a '((a . 1) (b . 2)) :test)
Error: 'assoc' unpaired keyword

unsupported keyword

The only keyword supported in assocmember, or search is :test. For example:

> (assoc 'a '((a . 1) (b . 2)) :key #'car)
Error: 'assoc' unsupported keyword: :key

Z

zero length string

The string supplied to read-from-string is empty. For example:

> (read-from-string "")
Error: 'read-from-string' zero length string