From 1ee60095dbe8ed407d4065c73cd323b804b85c66 Mon Sep 17 00:00:00 2001 From: Chris Pressey Date: Wed, 7 Feb 2018 13:43:41 +0000 Subject: [PATCH] Fairly minimal example that exhibits the problem. --- eg/vector-table.60p | 53 +++++++++++++++++++++++++++++++++++++++++++++ eg/vector.60p | 4 ++-- 2 files changed, 55 insertions(+), 2 deletions(-) create mode 100644 eg/vector-table.60p diff --git a/eg/vector-table.60p b/eg/vector-table.60p new file mode 100644 index 0000000..2ffb666 --- /dev/null +++ b/eg/vector-table.60p @@ -0,0 +1,53 @@ +vector routine + trashes a, z, n + print + +vector (routine + trashes a, z, n) + table[32] vectors + +routine chrout + inputs a + trashes a + @ 65490 + +routine printa + trashes a, z, n +{ + ld a, 65 + call chrout +} + +routine printb + trashes a, z, n +{ + ld a, 66 + call chrout +} + +routine main + inputs vectors + outputs vectors + trashes print, a, x, z, n, c +{ + ld x, 0 + copy printa, vectors + x + inc x + copy printa, vectors + x + inc x + copy printb, vectors + x + inc x + copy printa, vectors + x + inc x + copy printb, vectors + x + + copy printa, print + + ld x, 0 + repeat { + copy vectors + x, print + call print + inc x + cmp x, 5 + } until z +} diff --git a/eg/vector.60p b/eg/vector.60p index 0fa1d6c..fd86d93 100644 --- a/eg/vector.60p +++ b/eg/vector.60p @@ -1,5 +1,6 @@ -vector print +vector routine trashes a, z, n + print routine chrout inputs a @@ -21,7 +22,6 @@ routine printb } routine main - inputs printa, printb trashes print, a, z, n { copy printa, print