[llvm-commits] [llvm] r166035 - /llvm/trunk/include/llvm/Attributes.h
Bill Wendling
isanbard at gmail.com
Tue Oct 16 11:06:07 PDT 2012
Author: void
Date: Tue Oct 16 13:06:06 2012
New Revision: 166035
URL: http://llvm.org/viewvc/llvm-project?rev=166035&view=rev
Log:
Use the appropriate Attributes::get method to create an Attributes object.
Modified:
llvm/trunk/include/llvm/Attributes.h
Modified: llvm/trunk/include/llvm/Attributes.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/Attributes.h?rev=166035&r1=166034&r2=166035&view=diff
==============================================================================
--- llvm/trunk/include/llvm/Attributes.h (original)
+++ llvm/trunk/include/llvm/Attributes.h Tue Oct 16 13:06:06 2012
@@ -290,15 +290,9 @@
static AttributeWithIndex get(LLVMContext &C, unsigned Idx,
ArrayRef<Attributes::AttrVal> Attrs) {
- AttrBuilder B;
-
- for (ArrayRef<Attributes::AttrVal>::iterator I = Attrs.begin(),
- E = Attrs.end(); I != E; ++I)
- B.addAttribute(*I);
-
AttributeWithIndex P;
P.Index = Idx;
- P.Attrs = Attributes::get(C, B);
+ P.Attrs = Attributes::get(C, Attrs);
return P;
}
static AttributeWithIndex get(unsigned Idx, Attributes Attrs) {
More information about the llvm-commits
mailing list