We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 278bbf0 commit 6720584Copy full SHA for 6720584
tests/disassemble.py
@@ -52,6 +52,11 @@ def test_unknown_instruction():
52
assert_decode_exception("10000001", 'Unknown instruction')
53
54
55
+@test
56
+def test_empty_instruction():
57
+ assert_decode_exception("00000000", '<empty>')
58
+
59
60
# All hex sequences were generated using our assembler.
61
# Note: disassembled instructions always show field values according
62
# to what is actually encoded into the binary instruction, not as per
tools/disassemble.py
@@ -89,6 +89,9 @@
89
90
91
def decode_instruction(i):
92
+ if i == 0:
93
+ raise Exception('<empty>')
94
95
ins = opcodes._end
96
ins.all = i # abuse a struct to get opcode
97
0 commit comments