Use the AttributeSet query method instead of the Attribute method.

llvm-svn: 172849
This commit is contained in:
Bill Wendling
2013-01-18 21:26:07 +00:00
parent 7b5805d0d1
commit 63ffde573e

View File

@@ -1967,7 +1967,7 @@ static void replaceUsesOfNonProtoConstant(llvm::Constant *old,
continue;
llvm::Attribute fnAttrs = oldAttrs.getFnAttributes();
if (fnAttrs.hasAttributes())
if (oldAttrs.hasAttributes(llvm::AttributeSet::FunctionIndex))
newAttrs.push_back(llvm::
AttributeWithIndex::get(llvm::AttributeSet::FunctionIndex,
fnAttrs));