* src/hc08/gen.c: fixed MSVC warning C4146: unary minus operator applied to
authorborutr <borutr@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sun, 30 Sep 2007 06:59:18 +0000 (06:59 +0000)
committerborutr <borutr@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Sun, 30 Sep 2007 06:59:18 +0000 (06:59 +0000)
  unsigned type, result still unsigned

git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@4922 4a8a32a2-be11-0410-ad9d-d568d2c75423

src/hc08/gen.c

index d2e1fd9e1c8797ad4aa2aeecd2a9517592d9b2b7..e42d174faf1efc83a3d76c3d79a53484ed9b45ce 100644 (file)
@@ -3412,7 +3412,7 @@ genMinusDec (iCode * ic)
           needpulh = FALSE;
         }
       loadRegFromAop (hc08_reg_hx, AOP(left), 0);
-      emitcode ("aix","#%d", -icount);
+      emitcode ("aix","#%d", -(int) icount);
       hc08_dirtyReg (hc08_reg_hx, FALSE);
       storeRegToAop (hc08_reg_hx, AOP(result), 0);
       pullOrFreeReg (hc08_reg_h, needpulh);