From a5c6776929cd51f3bf86a126856669a66012b030 Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Wed, 25 Nov 2015 18:22:26 +0000 Subject: More examples --- examples/o.s | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 examples/o.s (limited to 'examples/o.s') diff --git a/examples/o.s b/examples/o.s new file mode 100644 index 0000000..5246a41 --- /dev/null +++ b/examples/o.s @@ -0,0 +1,34 @@ +;All operand types, presented in various ways + +:start set a, 5 + set a, b + set a, [b] + set a, [b + 3] + set a, [3 + b] ;both ways should be acceptable + set a, [b+3] ;spaces should not be forced + set a, POP + set a, PEEK + set PUSH, a + set a, start + set a, [start] + set a, PC + set a, SP + set a, O + + ;reverse these + + ;set 5, a ;allowable in the spec though + + set b, a + set [b], a + set [b + 3], a + set [3 + b], a + set [b+3], a + set POP, a + set PEEK, a + set a, PUSH + set start, a + set [start], a + set PC, a + set SP, a + set O, a -- cgit v1.2.3