Oops..need a cast here.
authorbdemsky <bdemsky>
Mon, 16 Aug 2004 20:12:33 +0000 (20:12 +0000)
committerbdemsky <bdemsky>
Mon, 16 Aug 2004 20:12:33 +0000 (20:12 +0000)
Repair/RepairCompiler/MCC/IR/Sources.java

index da41331..797644a 100755 (executable)
@@ -45,7 +45,7 @@ public class Sources {
        e.generate(cr, size);
        cr.popSymbolTable();
        cr.outputline(td.getGenerateType().getSafeSymbol()+" "+vd.getSafeSymbol()+"=("+td.getGenerateType().getSafeSymbol()+") calloc(1,"+size.getSafeSymbol()+");");
-       cr.outputline("alloc("+vd.getSafeSymbol()+","+size.getSafeSymbol()+");");
+       cr.outputline("alloc((void *) "+vd.getSafeSymbol()+","+size.getSafeSymbol()+");");
        if (Compiler.ALLOCATECPLUSPLUS) {
            if (td instanceof StructureTypeDescriptor) {
                if (((StructureTypeDescriptor)td).size()>0) {