jr .fail
rst $00
.jr:
+
+ ; Test inc16
+ ld d, $12
+ ld e, $FF
+ ld hl, .inc16fail
+ inc de
+ ld a, $13
+ cp d
+ jr nz, .fail
+ ld a, $00
+ cp e
+ jr nz, .fail
; Test CP.
ld hl, .cpfail
db "CP",0
.cplfail:
db "CPL",0
+.inc16fail:
+ db "INC16",0
.testfailed:
db " test failed.",$0D,$0A,0
.ok: