More support for DS80C400
[fw/sdcc] / src / SDCCopt.c
index 2e1ff9a6f2c65a1ef891b34b196723441501310d..ce59ec5732292088a803bdeb40f8991717c793e8 100644 (file)
@@ -925,7 +925,9 @@ eBBlockFromiCode (iCode * ic)
   if (!options.lessPedantic) {
     // this is a good place to check missing return values
     if (currFunc) {
-      if (!IS_VOID(currFunc->etype)) {
+      // the user is on his own with naked functions...
+      if (!IS_VOID(currFunc->etype)
+       && !FUNC_ISNAKED(currFunc->type)) {
        eBBlock *bp;
        // make sure all predecessors of the last block end in a return
        for (bp=setFirstItem(ebbs[saveCount-1]->predList);