mirror of
https://github.com/xomboverlord/ldc.git
synced 2026-08-29 09:40:04 +02:00
Use optimized array operators implemented in druntime
This commit is contained in:
@@ -1562,7 +1562,7 @@ bool mustDefineSymbol(Dsymbol* s)
|
||||
if (fd->semanticRun < 4)
|
||||
return false;
|
||||
|
||||
if (fd->isArrayOp)
|
||||
if (fd->isArrayOp == 1)
|
||||
return true;
|
||||
|
||||
if (global.params.useAvailableExternally && fd->availableExternally) {
|
||||
|
||||
@@ -33,7 +33,7 @@ static Module* getDefinedModule(Dsymbol* s)
|
||||
// array operations as well
|
||||
else if (FuncDeclaration* fd = s->isFuncDeclaration())
|
||||
{
|
||||
if (fd->isArrayOp)
|
||||
if (fd->isArrayOp == 1)
|
||||
return gIR->dmodule;
|
||||
}
|
||||
// otherwise use the symbol's module
|
||||
|
||||
@@ -267,7 +267,7 @@ LLGlobalValue::LinkageTypes DtoLinkage(Dsymbol* sym)
|
||||
if (fdecl->availableExternally && mustDefineSymbol(sym))
|
||||
return llvm::GlobalValue::AvailableExternallyLinkage;
|
||||
// array operations are always template linkage
|
||||
if (fdecl->isArrayOp)
|
||||
if (fdecl->isArrayOp == 1)
|
||||
return templateLinkage;
|
||||
// template instances should have weak linkage
|
||||
// but only if there's a body, and it's not naked
|
||||
|
||||
Reference in New Issue
Block a user