From e95c6ad8024975432162aef11918e7c06e0d207c Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Wed, 2 May 2007 21:39:20 +0000 Subject: Use 'static const char' instead of 'static const int'. Due to darwin gcc bug, one version of darwin linker coalesces static const int, which defauts PassID based pass identification. llvm-svn: 36652 --- llvm/lib/Analysis/BasicAliasAnalysis.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'llvm/lib/Analysis/BasicAliasAnalysis.cpp') diff --git a/llvm/lib/Analysis/BasicAliasAnalysis.cpp b/llvm/lib/Analysis/BasicAliasAnalysis.cpp index b1369a29206..1b728186ff2 100644 --- a/llvm/lib/Analysis/BasicAliasAnalysis.cpp +++ b/llvm/lib/Analysis/BasicAliasAnalysis.cpp @@ -36,7 +36,7 @@ namespace { /// such it doesn't follow many of the rules that other alias analyses must. /// struct VISIBILITY_HIDDEN NoAA : public ImmutablePass, public AliasAnalysis { - static const int ID; // Class identification, replacement for typeinfo + static const char ID; // Class identification, replacement for typeinfo NoAA() : ImmutablePass((intptr_t)&ID) {} virtual void getAnalysisUsage(AnalysisUsage &AU) const { @@ -77,7 +77,7 @@ namespace { }; // Register this pass... - const int NoAA::ID = 0; + const char NoAA::ID = 0; RegisterPass U("no-aa", "No Alias Analysis (always returns 'may' alias)"); @@ -92,7 +92,7 @@ namespace { /// Because it doesn't chain to a previous alias analysis (like -no-aa), it /// derives from the NoAA class. struct VISIBILITY_HIDDEN BasicAliasAnalysis : public NoAA { - static const int ID; // Class identification, replacement for typeinfo + static const char ID; // Class identification, replacement for typeinfo AliasResult alias(const Value *V1, unsigned V1Size, const Value *V2, unsigned V2Size); @@ -124,7 +124,7 @@ namespace { }; // Register this pass... - const int BasicAliasAnalysis::ID = 0; + const char BasicAliasAnalysis::ID = 0; RegisterPass X("basicaa", "Basic Alias Analysis (default AA impl)"); -- cgit v1.2.3