mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-13 06:28:52 +03:00
Adapt to free functions in dmd
C++ namespace now
This commit is contained in:
parent
217888ff47
commit
9041c0bf67
37 changed files with 132 additions and 64 deletions
|
@ -24,6 +24,8 @@
|
|||
#include "ir/irfunction.h"
|
||||
#include "ir/irmodule.h"
|
||||
|
||||
using namespace dmd;
|
||||
|
||||
// returns the keytype typeinfo
|
||||
static LLConstant *to_keyti(const Loc &loc, DValue *aa, LLType *targetType) {
|
||||
// keyti param
|
||||
|
@ -60,8 +62,8 @@ DLValue *DtoAAIndex(const Loc &loc, Type *type, DValue *aa, DValue *key,
|
|||
// call runtime
|
||||
LLValue *ret;
|
||||
if (lvalue) {
|
||||
LLValue *rawAATI =
|
||||
DtoTypeInfoOf(loc, aa->type->unSharedOf()->mutableOf(), /*base=*/false);
|
||||
auto t = mutableOf(unSharedOf(aa->type));
|
||||
LLValue *rawAATI = DtoTypeInfoOf(loc, t, /*base=*/false);
|
||||
LLValue *castedAATI = DtoBitCast(rawAATI, funcTy->getParamType(1));
|
||||
LLValue *valsize = DtoConstSize_t(getTypeAllocSize(DtoType(type)));
|
||||
ret = gIR->CreateCallOrInvoke(func, aaval, castedAATI, valsize, pkey,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue