diff options
Diffstat (limited to 'lib/IR/Function.cpp')
-rw-r--r-- | lib/IR/Function.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/IR/Function.cpp b/lib/IR/Function.cpp index cd35aff161..6a5e61611c 100644 --- a/lib/IR/Function.cpp +++ b/lib/IR/Function.cpp @@ -250,7 +250,9 @@ void Function::dropAllReferences() { void Function::addAttribute(unsigned i, Attribute attr) { AttributeSet PAL = getAttributes(); - PAL = PAL.addAttr(getContext(), i, attr); + AttrBuilder B(attr); + PAL = PAL.addAttributes(getContext(), i, + AttributeSet::get(getContext(), i, B)); setAttributes(PAL); } |