comparison gen/toir.cpp @ 193:aca17e55b7a5 trunk

[svn r209] Fixed: exotic array to pointer casts were broken. Changed: classes now have opaque vtables.
author lindquist
date Mon, 12 May 2008 18:44:11 +0200
parents 3cdf4b0c75a1
children bfcb657756f6
comparison
equal deleted inserted replaced
192:67ed21bf16af 193:aca17e55b7a5
1472 //Logger::cout() << "vthis: " << *vthis << '\n'; 1472 //Logger::cout() << "vthis: " << *vthis << '\n';
1473 funcval = DtoGEP(vthis, zero, zero, "tmp", p->scopebb()); 1473 funcval = DtoGEP(vthis, zero, zero, "tmp", p->scopebb());
1474 funcval = new llvm::LoadInst(funcval,"tmp",p->scopebb()); 1474 funcval = new llvm::LoadInst(funcval,"tmp",p->scopebb());
1475 funcval = DtoGEP(funcval, zero, vtblidx, toChars(), p->scopebb()); 1475 funcval = DtoGEP(funcval, zero, vtblidx, toChars(), p->scopebb());
1476 funcval = new llvm::LoadInst(funcval,"tmp",p->scopebb()); 1476 funcval = new llvm::LoadInst(funcval,"tmp",p->scopebb());
1477 #if OPAQUE_VTBLS
1478 funcval = DtoBitCast(funcval, getPtrToType(DtoType(fdecl->type)));
1479 Logger::cout() << "funcval casted: " << *funcval << '\n';
1480 #endif
1477 //assert(funcval->getType() == DtoType(fdecl->type)); 1481 //assert(funcval->getType() == DtoType(fdecl->type));
1478 //cc = DtoCallingConv(fdecl->linkage); 1482 //cc = DtoCallingConv(fdecl->linkage);
1479 } 1483 }
1480 // static call 1484 // static call
1481 else { 1485 else {