From: johanknol Date: Wed, 1 Aug 2001 07:50:06 +0000 (+0000) Subject: fixed the bit to int cast X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=64a9da6534ae075124cfbddbe1d2222cb0b42cb2;p=fw%2Fsdcc fixed the bit to int cast git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1118 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- diff --git a/src/mcs51/gen.c b/src/mcs51/gen.c index 2e64ad21..78725f19 100644 --- a/src/mcs51/gen.c +++ b/src/mcs51/gen.c @@ -1003,7 +1003,7 @@ aopPut (asmop * aop, char *s, int offset) } { symbol *lbl = newiTempLabel (NULL); - emitcode ("clr", "c"); + emitcode ("clr", "c; oops"); emitcode ("jz", "%05d$", lbl->key + 100); emitcode ("cpl", "c"); emitcode ("", "%05d$:", lbl->key + 100); @@ -8299,7 +8299,7 @@ genCast (iCode * ic) /* now depending on the sign of the source && destination */ size = AOP_SIZE (result) - AOP_SIZE (right); /* if unsigned or not an integral type */ - if (SPEC_USIGN (rtype) || !IS_SPEC (rtype)) + if (SPEC_USIGN (rtype) || !IS_SPEC (rtype) || AOP_TYPE(right)==AOP_CRY) { while (size--) aopPut (AOP (result), zero, offset++);