comparison dmd/Module.d @ 5:63623152e82a

Fixed memory corruption bug which was introduced when attempting to restore GC functionality
author dkoroskin <>
date Tue, 08 Dec 2009 21:39:17 +0300
parents d706d958e4e8
children 427f8aa74d28 2cc604139636
comparison
equal deleted inserted replaced
4:d706d958e4e8 5:63623152e82a
929 outdata(cov); 929 outdata(cov);
930 slist_add(cov); 930 slist_add(cov);
931 931
932 covb = cast(uint*)GC.calloc(((numlines + 32) / 32) * (*covb).sizeof); 932 covb = cast(uint*)GC.calloc(((numlines + 32) / 32) * (*covb).sizeof);
933 } 933 }
934 934
935 for (int i = 0; i < members.dim; i++) 935 for (int i = 0; i < members.dim; i++)
936 { 936 {
937 Dsymbol member = cast(Dsymbol)members.data[i]; 937 Dsymbol member = cast(Dsymbol)members.data[i];
938 member.toObjFile(multiobj); 938 member.toObjFile(multiobj);
939 } 939 }
940 940
941 if (global.params.cov) 941 if (global.params.cov)
942 { 942 {
943 /* Generate 943 /* Generate
944 * bit[numlines] __bcoverage; 944 * bit[numlines] __bcoverage;
945 */ 945 */
1122 ma.Sclass = SC.SCglobal; 1122 ma.Sclass = SC.SCglobal;
1123 ma.Sfl = 0; 1123 ma.Sfl = 0;
1124 writefunc(ma); 1124 writefunc(ma);
1125 } 1125 }
1126 } 1126 }
1127
1127 1128
1128 static if (true) { 1129 static if (true) {
1129 // Always generate module info, because of templates and -cov 1130 // Always generate module info, because of templates and -cov
1130 if (1 || needModuleInfo()) 1131 if (1 || needModuleInfo())
1131 genmoduleinfo(); 1132 genmoduleinfo();
1132 } 1133 }
1133 1134
1134 obj_termfile(); 1135 obj_termfile();
1135 } 1136 }
1136 1137
1137 void gensymfile() 1138 void gensymfile()