[cc65] cc65 #if bug

Date view Thread view Subject view

From: Tim Vanderhoek (vanderh_at_ecf.utoronto.ca)
Date: 2000-03-08 11:06:10


b$ cat bug.c

static char c;

void
f(void)
{
	c |= 8;
#if 0
#endif
}

b$ cc65-240 bug.c
b$ cat bug.s

; File generated by cc65 v 2.4.0

.fopt		compiler,"cc65 v 2.4.0"

.autoimport	+
.case		+
.debuginfo	-
.importzp	sp, sreg, regsave, regbank, tmp1, ptr1
.macpack	longbranch

.macro  ldax    Value
        lda     #<(Value)
        ldx     #>(Value)
.endmacro

.segment	"BSS"
_c:
	.res	1
.segment	"CODE"
_f:
	ldx	#$00
	lda	_c+0
	jsr	pushax
	ldx	#$00
	sta	_c+0
	rts

	.export		_f


[As an aside: I'm sorry I haven't had a chance to test the new
 load/run extenstion to the linker].


-- 
Signature withheld by request of author.
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo_at_musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.


Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2001-12-14 22:05:35 CET