Introduce SpecialCaseList::isIn overload for GlobalAliases.

Differential Revision: http://llvm-reviews.chandlerc.com/D1437

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188688 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Peter Collingbourne
2013-08-19 19:00:35 +00:00
parent 756e89c8c2
commit 2b762cc75d
3 changed files with 69 additions and 2 deletions

View File

@ -49,6 +49,7 @@
namespace llvm {
class Function;
class GlobalAlias;
class GlobalVariable;
class MemoryBuffer;
class Module;
@ -79,6 +80,14 @@ class SpecialCaseList {
bool isIn(const GlobalVariable &G,
const StringRef Category = StringRef()) const;
/// Returns whether this global alias is listed in the given category, which
/// may be omitted to search the empty category.
///
/// If GA aliases a function, the alias's name is matched as a function name
/// would be. Similarly, aliases of globals are matched like globals.
bool isIn(const GlobalAlias &GA,
const StringRef Category = StringRef()) const;
/// Returns whether this module is listed in the given category, which may be
/// omitted to search the empty category.
bool isIn(const Module &M, const StringRef Category = StringRef()) const;