From 1df9859c40492511b8aa4321eb76496005d3b75b Mon Sep 17 00:00:00 2001 From: Duncan Sands Date: Tue, 16 Feb 2010 11:11:14 +0000 Subject: There are two ways of checking for a given type, for example isa(T) and T->isPointerTy(). Convert most instances of the first form to the second form. Requested by Chris. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96344 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Analysis/BasicAliasAnalysis.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/Analysis/BasicAliasAnalysis.cpp') diff --git a/lib/Analysis/BasicAliasAnalysis.cpp b/lib/Analysis/BasicAliasAnalysis.cpp index 36b831c0ef..31a649d5cc 100644 --- a/lib/Analysis/BasicAliasAnalysis.cpp +++ b/lib/Analysis/BasicAliasAnalysis.cpp @@ -290,7 +290,7 @@ BasicAliasAnalysis::getModRefInfo(CallSite CS, Value *P, unsigned Size) { for (CallSite::arg_iterator CI = CS.arg_begin(), CE = CS.arg_end(); CI != CE; ++CI, ++ArgNo) { // Only look at the no-capture pointer arguments. - if (!isa((*CI)->getType()) || + if (!(*CI)->getType()->isPointerTy() || !CS.paramHasAttr(ArgNo+1, Attribute::NoCapture)) continue; @@ -662,7 +662,7 @@ BasicAliasAnalysis::aliasCheck(const Value *V1, unsigned V1Size, // Are we checking for alias of the same value? if (V1 == V2) return MustAlias; - if (!isa(V1->getType()) || !isa(V2->getType())) + if (!V1->getType()->isPointerTy() || !V2->getType()->isPointerTy()) return NoAlias; // Scalars cannot alias each other // Figure out what objects these things are pointing to if we can. -- cgit v1.2.3-18-g5258