From: Oliver Schmidt Date: Sun, 7 Apr 2013 20:26:19 +0000 (+0200) Subject: Allow for warning-free build of cc65 with MS VC on warning level 3. X-Git-Tag: V2.14~71 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=be83b87463c0055fb9d2a2fdcf20e775c841bea6;p=cc65 Allow for warning-free build of cc65 with MS VC on warning level 3. --- diff --git a/src/cc65/coptstore.c b/src/cc65/coptstore.c index d5dad45e4..03d8ab32f 100644 --- a/src/cc65/coptstore.c +++ b/src/cc65/coptstore.c @@ -133,9 +133,9 @@ unsigned OptStore2 (CodeSeg* S) !RegAXUsed (S, I+1)) { /* Get the register values */ - unsigned char A = RI->In.RegA; - unsigned char X = RI->In.RegX; - unsigned char Y = RI->In.RegY; + unsigned char A = (unsigned char) RI->In.RegA; + unsigned char X = (unsigned char) RI->In.RegX; + unsigned char Y = (unsigned char) RI->In.RegY; /* Setup other variables */ CodeEntry* N; @@ -205,11 +205,11 @@ unsigned OptStore3 (CodeSeg* S) !RegEAXUsed (S, I+1)) { /* Get the register values */ - unsigned char A = RI->In.RegA; - unsigned char X = RI->In.RegX; - unsigned char Y = RI->In.RegY; - unsigned char L = RI->In.SRegLo; - unsigned char H = RI->In.SRegHi; + unsigned char A = (unsigned char) RI->In.RegA; + unsigned char X = (unsigned char) RI->In.RegX; + unsigned char Y = (unsigned char) RI->In.RegY; + unsigned char L = (unsigned char) RI->In.SRegLo; + unsigned char H = (unsigned char) RI->In.SRegHi; /* Setup other variables */ unsigned Done = 0;