Errors¶
The table below lists the errors that Monster may report while assembling, linking, debugging, or performing file I/O. Each error has a numeric code and an on-screen message. Some messages are self-explanatory; others are described in more detail below.
CODE |
MESSAGE |
DESCRIPTION |
|---|---|---|
|
STACK UNDERFLOW |
Monster uses stacks for various things (e.g. nested |
|
STACK OVERFLOW |
as above, but a context-dependent stack has overflowed |
|
OVERSIZED LINE |
a line was found that is over the maximum length of 40 characters |
|
INVALID EXPRESSION |
the expression could not be successfully parsed |
|
INVALID MACRO ARGS |
the macro was invoked with the wrong number of, or invalid, arguments |
|
SYNTAX ERROR |
general error; typically means an instruction is malformed |
|
INVALID DIRECTIVE |
a |
|
LABEL UNDEFINED |
an attempt was made to look up a label with a name that no label exists for |
|
ENDIF WITH NO IF |
an |
|
TOO MANY MACROS |
the maximum number of macros (128) has been exceeded |
|
LABEL NOT LEFT ALIGNED |
something that looks like a label definition was found, but it is not in the leftmost column |
|
INVALID OPCODE |
something that looks like an opcode was found, but it does not match any known opcode |
|
INVALID ADDR MODE |
the address mode used for an instruction is not legal for that opcode (e.g. |
|
OVERSIZED OPERAND |
the operand for an instruction is too big (e.g. |
|
INVALID LABEL |
a label definition was found, but it contains invalid characters |
|
LABEL TOO LONG |
a label definition was found, but it exceeds the maximum length (16 characters) |
|
UNEXPECTED CHAR |
a garbage character was encountered; the instruction or operand may be malformed |
|
EXPECTED VALUE |
a value was expected but none was found (e.g. a missing operand) |
|
I/O ERROR |
general-purpose error from disk access |
|
NO MACRO NAME |
a macro definition was made, but it is missing a name (1st parameter) |
|
LABEL UNRESOLVABLE |
a label was referenced in the second assembly pass, but the assembler still hasn’t seen a definition for it |
|
CYCLIC INCLUDE |
a file includes itself, directly or indirectly |
|
FAILED TO OPEN INCLUDE FILE |
an |
|
SEGMENT OVERLAP |
two segments overlap in the final linked layout |
|
TOO MANY FILES |
there are too many files |
|
PARAM NAME TOO LONG |
a macro’s parameter name is too long — parameter names must be 16 characters at most |
|
LINE NOT FOUND FOR ADDRESS |
no line was found for the address that was used to look one up |
|
ORIGIN UNSET |
an instruction was found before the program was given an origin ( |
|
RANGE ERROR |
branch target is too far; relative branch targets must be within [-128, 127] bytes of the branch |
|
FILE NOT FOUND |
a file was not found for the requested filename |
|
UNKNOWN SEGMENT |
a segment was referenced that is not defined (linker) |
|
IMPORT UNDEFINED |
an imported symbol has no matching export at link time |
|
PC TARGET UNWRITABLE |
the PC has reached an address that is not writable (e.g. ROM), so the assembler cannot write to it |
|
CANNOT REDUCE EXPRESSION |
an expression contains an invalid combination of relative and absolute references; define the symbol ahead of its usage so it is resolvable |
|
TOO MANY OPEN FILES |
the maximum number of files that may be open (15) has been exceeded |
|
LOGICAL FILE IN USE |
the logical file number is already in use |
|
NO DRIVE RESPONSE |
the selected disk drive did not respond |
|
FILE TOO BIG |
the file requested to be loaded is too big to fit in a source buffer (24KB) |
|
UNNAMED BUFFER |
an operation (e.g. producing debug information for a line) requires the buffer to have a name, but it has none |
|
TOO MANY OPEN BUFFERS |
the maximum number of source buffers (8) is already open |
|
NO FILENAME |
the command requires a filename (e.g. SAVE), but none was given |
|
NO OPEN SCOPE |
a local label was defined, but there is no open scope for it to be defined under |
|
LABEL ALREADY DEFINED |
a label with the name of another one already exists |
|
TOO MANY LABELS |
the maximum number of named labels (640) has been exceeded |
|
LABEL NOT KNOWN IN PASS 1 |
the address of a label was incorrectly inferred in pass 1; typically an operand assumed absolute turned out to be zero page |
|
INVALID COMMAND |
an invalid monitor command was provided |
|
COPY TOO BIG |
a copy was attempted that exceeded the maximum size |
|
BUFFER NAME EXISTS |
the buffer could not be given the suggested name because a buffer of the same name is already loaded |
|
BUFFER FULL |
an insertion into a buffer could not be completed because the buffer is already full |
|
TOO MANY GLOBAL REFS |
the linker’s global reference table has been exceeded |
|
TOO MANY SEGMENTS |
the maximum number of segments (64) has been exceeded (linker) |
|
SECTION OVERRUN |
a section is too small to hold the segments assigned to it (linker) |
|
CONFLICTING ADDRESS MODES FOR SYMBOL |
a symbol was defined/used with conflicting address modes (zero page vs absolute) across object files |
|
MULTIPLE DEFINITIONS FOR SYMBOL |
a symbol is exported (defined) in more than one object file |
|
UNKNOWN TYPE |
an unknown segment TYPE was specified in the LINK file |
|
UNEXPECTED TYPE |
a segment TYPE was used somewhere it is not allowed |
|
CONFLICTING SEGMENT TYPES |
a segment was declared with conflicting types across object files |
|
BSS SEGMENT CONTAINS NONZERO DATA |
a BSS segment (which must be uninitialized) contains nonzero data |
|
OUT OF MEMORY |
a buffer (context-dependent) has run out of memory |
|
CONTEXT FULL |
an internal context buffer is full |
|
NO MATCHING SCOPE |
a scope-closing construct has no matching open scope |
|
FILENAME TOO LONG |
a filename exceeds the maximum length |
|
TOO MANY WATCHES |
the maximum number of watches (8) has been exceeded |
|
TOO MANY BREAKPOINTS |
the maximum number of breakpoints (16) has been exceeded |
|
RORG REQUIRES ABSOLUTE ORIGIN |
|
|
UNCLOSED .IF |
an |
|
UNCLOSED .MAC OR .REP |
a |
|
CANNOT ASSEMBLE LOG |
an attempt was made to assemble the LOG buffer |
|
DIVIDE BY ZERO |
an expression attempted a division by zero |
|
DUPLICATE BLOCK |
a LINK file declares its |
|
UNKNOWN KEY |
a LINK file uses an unrecognized property key in a memory section or segment definition |
|
NO SEGMENTS DEFINED |
no segments were defined for the linker to place |
|
TOO MANY NESTED IFS |
the maximum nesting depth of 8 |
|
TOO MANY IFDEFS |
the maximum of 255 |
|
IFDEF PASS MISMATCH |
pass 2 encountered an |
|
MISSING REQUIRED KEY |
a LINK file definition omits a required property ( |
|
TOO MANY OBJECTS |
more object files were given to the linker than it can link at once (16) |
|
DUPLICATE NAME |
a LINK file declares two memory sections, or two segments, with the same name |
|
SEGMENT OUT OF RANGE |
a segment’s placement runs past the top of the address space ( |
|
NON INTEGRAL VALUE |
a floating point value was used where only an integer is allowed |
|
INVALID ALIGNMENT |
a LINK file segment’s |
|
WATCH ALREADY EXISTS |
the monitor already has a watch for the same address or exact range; remove it before adding another mode |