From dded9a9b5ed895064bab8b5951f44c18c639430b Mon Sep 17 00:00:00 2001 From: michaelh Date: Mon, 20 Aug 2001 04:39:03 +0000 Subject: [PATCH] Added simple assertions to help bug tracking git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1156 4a8a32a2-be11-0410-ad9d-d568d2c75423 --- src/mcs51/gen.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/mcs51/gen.c b/src/mcs51/gen.c index e2dad877..ccaacd08 100644 --- a/src/mcs51/gen.c +++ b/src/mcs51/gen.c @@ -273,7 +273,12 @@ static asmop * aopForSym (iCode * ic, symbol * sym, bool result) { asmop *aop; - memmap *space = SPEC_OCLS (sym->etype); + memmap *space; + + wassertl (ic != NULL, "Got a null iCode"); + wassertl (sym != NULL, "Got a null symbol"); + + space = SPEC_OCLS (sym->etype); /* if already has one */ if (sym->aop) -- 2.47.2