mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-08 03:46:02 +03:00
2nd attempt on the latest LLVM 3.3 changes.
The previous commit only worked on Windows.
This commit is contained in:
parent
26385c55fe
commit
c0284bac2b
1 changed files with 4 additions and 3 deletions
|
@ -613,11 +613,12 @@ static void set_param_attrs(TypeFunction* f, llvm::Function* func, FuncDeclarati
|
||||||
#endif
|
#endif
|
||||||
for (size_t i = 0; i < oldAttrs.getNumSlots(); ++i) {
|
for (size_t i = 0; i < oldAttrs.getNumSlots(); ++i) {
|
||||||
#if LDC_LLVM_VER >= 303
|
#if LDC_LLVM_VER >= 303
|
||||||
llvm::AttributeWithIndex curr = llvm::AttributeWithIndex::get(oldAttrs.getSlotIndex(i),
|
const unsigned Index = oldAttrs.getSlotIndex(i);
|
||||||
|
llvm::AttrBuilder &builder = llvm::AttrBuilder(oldAttrs.getSlotAttributes(i), Index).addAttribute(llvm::Attribute::None);
|
||||||
|
llvm::AttributeWithIndex curr = llvm::AttributeWithIndex::get(Index,
|
||||||
llvm::Attribute::get(
|
llvm::Attribute::get(
|
||||||
gIR->context(),
|
gIR->context(),
|
||||||
llvm::AttrBuilder(oldAttrs.getSlotAttributes(i),
|
builder));
|
||||||
oldAttrs.getSlotIndex(i))));
|
|
||||||
#else
|
#else
|
||||||
llvm::AttributeWithIndex curr = oldAttrs.getSlot(i);
|
llvm::AttributeWithIndex curr = oldAttrs.getSlot(i);
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue