fixed bug #503216
authorjohanknol <johanknol@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Mon, 14 Jan 2002 10:18:53 +0000 (10:18 +0000)
committerjohanknol <johanknol@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Mon, 14 Jan 2002 10:18:53 +0000 (10:18 +0000)
git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1800 4a8a32a2-be11-0410-ad9d-d568d2c75423

src/avr/gen.c
src/ds390/gen.c
src/mcs51/gen.c

index 638182ab0d4e9eeb6c279864df83d729d03b8777..c44c40a2595956aaee67b6f25a854976b6ffe2e6 100644 (file)
@@ -290,6 +290,7 @@ hasInc (operand *op, iCode *ic)
        int isize ;
   
        if (IS_BITVAR(retype)||!IS_PTR(type)) return NULL;
+       if (IS_AGGREGATE(type->next)) return NULL;
        isize = getSize(type->next);
        while (lic) {
                /* if operand of the form op = op + <sizeof *op> */
index 875b591389b8869ee9958b3323805402eedd6951..9ade1a7f6be855cd2410fa2d655f46ffa03aaa28 100644 (file)
@@ -5594,7 +5594,9 @@ hasInc (operand *op, iCode *ic, int osize)
   if (!IS_SYMOP(op)) return NULL;
 
   if (IS_BITVAR(retype)||!IS_PTR(type)) return NULL;
+  if (IS_AGGREGATE(type->next)) return NULL;
   if (osize != (isize = getSize(type->next))) return NULL;
+
   while (lic) {
       /* if operand of the form op = op + <sizeof *op> */
       if (lic->op == '+' && isOperandEqual(IC_LEFT(lic),op) &&
index 63106da72587e28be1544659cc329384a2a34b7a..4d1f4394866d0417a868c265567f2e7ce0f5cf92 100644 (file)
@@ -4357,7 +4357,9 @@ hasInc (operand *op, iCode *ic,int osize)
   if (!IS_SYMOP(op)) return NULL;
 
   if (IS_BITVAR(retype)||!IS_PTR(type)) return NULL;
+  if (IS_AGGREGATE(type->next)) return NULL;
   if (osize != (isize = getSize(type->next))) return NULL;
+
   while (lic) {
     /* if operand of the form op = op + <sizeof *op> */
     if (lic->op == '+' && isOperandEqual(IC_LEFT(lic),op) &&