]> git.sur5r.net Git - cc65/commitdiff
Added an entry point that clears the high word of rhs.
authoruz <uz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Sun, 16 Aug 2009 16:38:52 +0000 (16:38 +0000)
committeruz <uz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Sun, 16 Aug 2009 16:38:52 +0000 (16:38 +0000)
git-svn-id: svn://svn.cc65.org/cc65/trunk@4027 b7a2c559-68d2-44c3-8de9-860c34a00d81

libsrc/runtime/lrsub.s

index 607b7fed299c477a2c8ade9ccc46c6fda5212df4..7dfe43ac5a04d17187cc300b53884d727aee3699 100644 (file)
@@ -7,11 +7,16 @@
 ;
 ; EAX = EAX - TOS
 ;
-       .export         tosrsubeax
+       .export         tosrsub0ax, tosrsubeax
        .import         addysp1
        .importzp       sp, sreg, tmp1
 
-tosrsubeax:
+tosrsub0ax:
+        ldy     #$00
+        sty     sreg
+        sty     sreg+1
+
+tosrsubeax:                         
        ldy     #0
                sec
        sbc     (sp),y          ; byte 0