Mercurial > projects > ldc
comparison gen/toir.cpp @ 367:519adb3128b1 trunk
[svn r388] ClassInfo declaration could fail if base classdecl hadn't been resolved.
Use ForceDeclare on the class decl instead of declaring class info only.
author | ChristianK |
---|---|
date | Tue, 15 Jul 2008 08:17:43 +0200 |
parents | bfb9d28f045a |
children | d8234836b40f |
comparison
equal
deleted
inserted
replaced
366:1d3026702f65 | 367:519adb3128b1 |
---|---|
210 } | 210 } |
211 // classinfo | 211 // classinfo |
212 else if (ClassInfoDeclaration* cid = vd->isClassInfoDeclaration()) | 212 else if (ClassInfoDeclaration* cid = vd->isClassInfoDeclaration()) |
213 { | 213 { |
214 Logger::println("ClassInfoDeclaration: %s", cid->cd->toChars()); | 214 Logger::println("ClassInfoDeclaration: %s", cid->cd->toChars()); |
215 DtoDeclareClassInfo(cid->cd); | 215 DtoForceDeclareDsymbol(cid->cd); |
216 assert(cid->cd->ir.irStruct->classInfo); | 216 assert(cid->cd->ir.irStruct->classInfo); |
217 return new DVarValue(vd, cid->cd->ir.irStruct->classInfo, true); | 217 return new DVarValue(vd, cid->cd->ir.irStruct->classInfo, true); |
218 } | 218 } |
219 // nested variable | 219 // nested variable |
220 else if (vd->nestedref) { | 220 else if (vd->nestedref) { |