From: johanknol Date: Sun, 7 Oct 2001 13:21:54 +0000 (+0000) Subject: let's not assume it is a symbol X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=a8bbb10d9bb1feaaf9ce2d801fe921e6dca6400a;p=fw%2Fsdcc let's not assume it is a symbol git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1366 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- diff --git a/src/mcs51/gen.c b/src/mcs51/gen.c index 4a7e6aba..630e1192 100644 --- a/src/mcs51/gen.c +++ b/src/mcs51/gen.c @@ -4208,6 +4208,9 @@ hasInc (operand *op, iCode *ic) iCode *lic = ic->next; int isize ; + /* this could from a cast, e.g.: "(char xdata *) 0x7654;" */ + if (!IS_SYMOP(op)) return NULL; + if (IS_BITVAR(retype)||!IS_PTR(type)) return NULL; isize = getSize(type->next); while (lic) {