Use the attribute enums to query if a function has an attribute.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165551 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Bill Wendling
2012-10-09 21:49:51 +00:00
parent 3e2d76c946
commit 2fa8af224e
4 changed files with 22 additions and 141 deletions

View File

@@ -132,7 +132,7 @@ static const AllocFnsTy *getAllocationData(const Value *V, AllocType AllocTy,
static bool hasNoAliasAttr(const Value *V, bool LookThroughBitCast) {
ImmutableCallSite CS(LookThroughBitCast ? V->stripPointerCasts() : V);
return CS && CS.fnHasNoAliasAttr();
return CS && CS.hasFnAttr(Attributes::NoAlias);
}