Quote:
Originally Posted by pipper
What I don't understand: why bitwise negating a 16bit number does not result in a 16bit number - is this a bug in vasm maybe?
|
The expression evaluation routine doesn't know anything about the instruction and it always works with the CPU's native target-address-type, which is 32 bits for M68k (would be 16 bits for 6502, for example).
So equates are always stored as 32 bit values. And eval_expression() always returns $ffff7fff for ~$8000. Then the AND.W instruction checks its immediate operand, which doesn't match its current operation size...
Yes, I think all assemblers work that way. Otherwise I have to fix it.