Closed ZornsLemma closed 3 years ago
Well spotted. This was only called from two places and the y register seems to have been non-zero at all times so it didn't matter but still a bug. Fixed. I've also checked all other calls to read_next_byte to verify that they aren't followed by a bad beq/bne, but this was the only instance.
This subroutine does:
It looks to me like the beq is intended to reflect the value returned in A by read_next_byte. But read_next byte always returns by doing:
so the beq in calculate_property_length_number will always be based on the value which happened to be in Y.
I think we need a 'cmp #0' between the two quoted lines of calculate_property_length_number.