aboutsummaryrefslogtreecommitdiff
path: root/bas.h
diff options
context:
space:
mode:
authorB. Watson <urchlay@slackware.uk>2024-06-08 13:12:23 -0400
committerB. Watson <urchlay@slackware.uk>2024-06-08 13:12:23 -0400
commit739758781030f107f260f587a4f9c1e8bdf70f58 (patch)
tree3a18b7bb2f87db35c7fad6124331d351ed713773 /bas.h
parentcb69895c4dbff77fe6e2eb1cf513ee7b2f3911f3 (diff)
downloadbw-atari8-tools-739758781030f107f260f587a4f9c1e8bdf70f58.tar.gz
dumpbas: clean up code, work on doc.
Diffstat (limited to 'bas.h')
-rw-r--r--bas.h21
1 files changed, 21 insertions, 0 deletions
diff --git a/bas.h b/bas.h
index 8168aa1..9d117cc 100644
--- a/bas.h
+++ b/bas.h
@@ -30,6 +30,27 @@
/* tokenized colon (statement separator) */
#define TOK_COLON 0x14
+/* BASIC tokens. Not a full set. BASIC uses 2 sets of tokens, one
+ for commands and the other for operators (which is to say, everything
+ *not* a command). */
+#define CMD_GOTO 0x0a
+#define CMD_GO_TO 0x0b
+#define CMD_GOSUB 0x0c
+#define CMD_TRAP 0x0d
+#define CMD_LIST 0x04
+#define CMD_RESTORE 0x23
+#define CMD_REM 0x00
+#define CMD_DATA 0x01
+#define CMD_ERROR 0x37
+#define OP_GOTO 0x17
+#define OP_GOSUB 0x18
+#define OP_THEN 0x1b
+#define OP_COMMA 0x12
+#define OP_EOS 0x14
+#define OP_EOL 0x16
+#define OP_NUMCONST 0x0e
+#define OP_STRCONST 0x0f
+
/* variable types, bits 6-7 of byte 0 of each vvtable entry. */
#define TYPE_SCALAR 0
#define TYPE_ARRAY 1