[stella] DASM: Bug

Subject: [stella] DASM: Bug
From: "Andrew Davie" <atari2600@xxxxxxxxxxxxx>
Date: Fri, 27 Feb 2004 23:25:23 +1100
I have just discovered a bug I have introduced into dasm.
In the following code...

VALUE    = $80

    and #VALUE            ; works OK
    and #~VALUE            ; fails

The problem is that ~VALUE becomes 16-bits and then we get

    and #$FF7F

... which is, of course, illegal.

The quick fix is to use

    and #(~VALUE)&$FF

It's ugly, but until I find some time to correct this error, please either
use an earlier version of DASM, or the above workaround.  This, of course,
means the current version of DASM may not be able to compile legacy code


Archives (includes files) at http://www.biglist.com/lists/stella/archives/
Unsub & more at http://www.biglist.com/lists/stella/

Current Thread