From: MaartenBrock Date: Tue, 6 Feb 2007 23:26:46 +0000 (+0000) Subject: * device/lib/printf_large.c (_print_format): fixed compare/assign bug, how X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=c15c41e6e023a757a9b96b84944faa37d117ae72;p=fw%2Fsdcc * device/lib/printf_large.c (_print_format): fixed compare/assign bug, how can this have lived here for so many years? * src/SDCCicode.c (ast2iCode): return left instead of right for assignment, fixes bug 1273984, see also patch 1645121, thanks Günther Jehle git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@4621 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- diff --git a/ChangeLog b/ChangeLog index 5e2bcd5a..122901e5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2007-02-07 Maarten Brock + + * device/lib/printf_large.c (_print_format): fixed compare/assign bug, how + can this have lived here for so many years? + * src/SDCCicode.c (ast2iCode): return left instead of right for assignment, + fixes bug 1273984, see also patch 1645121, thanks Günther Jehle + 2007-02-06 Bernhard Held * src/SDCCBlock.c (addiCodeToeBBlock): fixed bug 1652207: GOTO icodes diff --git a/device/lib/printf_large.c b/device/lib/printf_large.c index cb469b61..9df2285a 100644 --- a/device/lib/printf_large.c +++ b/device/lib/printf_large.c @@ -470,7 +470,7 @@ get_conversion_spec: } if (c=='.') { - if (decimals=-1) decimals=0; + if (decimals==-1) decimals=0; else ; // duplicate, ignore goto get_conversion_spec; diff --git a/src/SDCCicode.c b/src/SDCCicode.c index 9136a4cb..dc027f75 100644 --- a/src/SDCCicode.c +++ b/src/SDCCicode.c @@ -4290,8 +4290,7 @@ ast2iCode (ast * tree,int lvl) else right = geniCodeRValue (right, FALSE); - geniCodeAssign (left, right, 0, 1); - return right; + return geniCodeAssign (left, right, 0, 1); } case MUL_ASSIGN: return