aboutsummaryrefslogtreecommitdiff
path: root/src/65c816.c
diff options
context:
space:
mode:
authorIan C <ianc@noddybox.co.uk>2016-04-25 18:41:34 +0100
committerIan C <ianc@noddybox.co.uk>2016-04-25 18:41:34 +0100
commitae3e76a90ce0b6c810471d6602ffadf6bd182337 (patch)
tree97d66d072a45f904db8fb5345752d23f607934bd /src/65c816.c
parent6ca71dd7a7f10fa6857f1a1bc586059cd78e275a (diff)
Pre-merge
Diffstat (limited to 'src/65c816.c')
-rw-r--r--src/65c816.c44
1 files changed, 44 insertions, 0 deletions
diff --git a/src/65c816.c b/src/65c816.c
index 0fbf8bc..7313905 100644
--- a/src/65c816.c
+++ b/src/65c816.c
@@ -207,6 +207,50 @@ static void CalcAddressMode(int argc, char *argv[], int quoted[],
}
+ /* Absolute Indirect
+ */
+ if (argc == 1 && quoted[1] == '(')
+ {
+ if (!ExprEval(argv[1], address))
+ {
+ snprintf(err, errsize, "%s: expression error: %s",
+ argv[1], ExprError());
+ *mode = ADDR_MODE_ERROR;
+ return;
+ }
+
+ CMD_RANGE_ADDR_MODE(mode,
+ DIRECT_PAGE_INDIRECT,
+ ABSOLUTE_INDIRECT,
+ ADDR_MODE_ERROR,
+ address);
+
+ return;
+ }
+
+
+ /* Absolute Indirect Long
+ */
+ if (argc == 1 && quoted[1] == '[')
+ {
+ if (!ExprEval(argv[1], address))
+ {
+ snprintf(err, errsize, "%s: expression error: %s",
+ argv[1], ExprError());
+ *mode = ADDR_MODE_ERROR;
+ return;
+ }
+
+ CMD_RANGE_ADDR_MODE(mode,
+ DIRECT_PAGE_INDIRECT_LONG,
+ ABSOLUTE_INDIRECT_LONG,
+ ADDR_MODE_ERROR,
+ address);
+
+ return;
+ }
+
+
/* Absolute,[XY]
*/
if (argc == 3 && !quoted[1])