main.GetILGenerator().Emit(OpCodes.Ret); ((AssemblyBuilder)currModule.Assembly).SetEntryPoint(main);
    public void finalizeGen() {	tc.createTypes();	main.GetILGenerator().Emit(OpCodes.Ret);	((AssemblyBuilder)currModule.Assembly).SetEntryPoint(main);	try {	    Iterator iter = assemblies.values().iterator();	    while (iter.hasNext()) {		AssemblyBuilder assem = (AssemblyBuilder) iter.next();// 		log("Types defined in assembly: " + assem.FullName);// 		Type[] types = assem.GetTypes();// 		for (int i = 0; i < types.length; i++)// 		    log("\t" + types[i]);		assem.Save(assem.GetName().Name + ".il");	    }	}	catch (IOException e) { 	    if (global.debug) e.printStackTrace(); 	}    }