Fix thinko

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11027 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Chris Lattner 2004-01-30 22:48:02 +00:00
parent 847df25e7d
commit a4dd6743e7

View File

@ -130,9 +130,9 @@ static const Value *GetGEPOperands(const Value *V, std::vector<Value*> &GEPOps){
/// pointsToConstantMemory - Chase pointers until we find a (constant
/// global) or not.
bool BasicAliasAnalysis::pointsToConstantMemory(const Value *P) {
const Value *V = getUnderlyingObject(P);
if (const GlobalVariable *GV = dyn_cast<GlobalVariable>(V))
return GV->isConstant();
if (const Value *V = getUnderlyingObject(P))
if (const GlobalVariable *GV = dyn_cast<GlobalVariable>(V))
return GV->isConstant();
return false;
}