Website Summary Files Commits Branches @commit @diff @stats
path: root / spasm / src / asm / bytecode.hpp
diff options
context:
space:
mode:
Commita7cd9d4f8d83024402bacb39786e5e1a018a0a04 (patch)
Author
 Dimitar Trendafilov <dimitar@coherent-labs.com>
2018-11-14 23:45:56 +0200
Committer
 Martin Dobrev <martindobrev0@gmail.com>
2018-11-14 23:45:56 +0200
Files1f99c6f8d00d9b94b69c8f3525643344a32d7414 /spasm/src/asm/bytecode.hpp
IPL-a7cd9d4f8d83024402bacb39786e5e1a018a0a04.tar
IPL-a7cd9d4f8d83024402bacb39786e5e1a018a0a04.tar.gz
IPL-a7cd9d4f8d83024402bacb39786e5e1a018a0a04.zip
Parent9a7a8a31e75d1b85274ef46ca29714270062809e (diff)
Spasm can assemble programs on with the new instruction set (#47)
* Use checkout as-is, commit as-is * Spasm can assemble programs based on the new instruction set
1 files changed, 1 insertions, 24 deletions
-rw-r--r--spasm/src/asm/bytecode.hpp25
diff --git a/spasm/src/asm/bytecode.hpp b/spasm/src/asm/bytecode.hpp
index c08da46..d249db8 100644
--- a/spasm/src/asm/bytecode.hpp
+++ b/spasm/src/asm/bytecode.hpp
@@ -14,30 +14,7 @@ class Bytecode_Stream
{
public:
typedef unsigned char byte;
- enum Opcode_t : byte
- {
- halt = 0,
- push,
- pop,
- dup,
- print,
- read,
- plus,
- minus,
- multiply,
- divide,
- modulus,
- gotrue,
- gofalse,
- go,
- call,
- ret,
- load,
- store,
- less,
- lesseq
- };
-
+ typedef byte Opcode_t;
virtual ~Bytecode_Stream();
virtual void push_opcode(Opcode_t) = 0;