diff z80inst.c @ 313:a13329645ea3

Fix terminal instruction detection in disassembler
author Mike Pavone <pavone@retrodev.com>
date Thu, 09 May 2013 19:24:18 -0700
parents 147e31983730
children 54c0e5f22198
line wrap: on
line diff
--- a/z80inst.c	Thu May 09 18:36:21 2013 -0700
+++ b/z80inst.c	Thu May 09 19:24:18 2013 -0700
@@ -1531,4 +1531,11 @@
 	}
 }
 
+uint8_t z80_is_terminal(z80inst * inst)
+{
+	return inst->op == Z80_RET || inst->op == Z80_RETI || inst->op == Z80_RETN || inst->op == Z80_JP
+		|| inst->op == Z80_JR || inst->op == Z80_HALT || (inst->op == Z80_NOP && inst->immed == 42);
+}
 
+
+