mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-08 20:06:03 +03:00
Fixed calling of _d_array_bounds and _d_switch_error.
This commit is contained in:
parent
3c4db7bc87
commit
a86f414bc1
7 changed files with 87 additions and 21 deletions
|
@ -1555,9 +1555,16 @@ void SwitchErrorStatement::toIR(IRState* p)
|
|||
|
||||
std::vector<LLValue*> args;
|
||||
|
||||
#if DMDV2
|
||||
// module param
|
||||
LLValue *moduleInfoSymbol = gIR->func()->decl->getModule()->moduleInfoSymbol();
|
||||
const LLType *moduleInfoType = DtoType(Module::moduleinfo->type);
|
||||
args.push_back(DtoBitCast(moduleInfoSymbol, getPtrToType(moduleInfoType)));
|
||||
#else
|
||||
// file param
|
||||
IrModule* irmod = getIrModule(NULL);
|
||||
args.push_back(DtoLoad(irmod->fileName));
|
||||
#endif
|
||||
|
||||
// line param
|
||||
LLConstant* c = DtoConstUint(loc.linnum);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue