Add dump method for selectors

Differential Revision: https://reviews.llvm.org/D45935
Reviewers: compnerd

llvm-svn: 333657
This commit is contained in:
Aditya Kumar 2018-05-31 14:45:32 +00:00
parent 2e41c5a79c
commit 6995821e90
2 changed files with 4 additions and 0 deletions

View File

@ -763,6 +763,8 @@ public:
/// Prints the full selector name (e.g. "foo:bar:").
void print(llvm::raw_ostream &OS) const;
void dump() const;
/// Derive the conventional family of this method.
ObjCMethodFamily getMethodFamily() const {
return getMethodFamilyImpl(*this);

View File

@ -504,6 +504,8 @@ void Selector::print(llvm::raw_ostream &OS) const {
OS << getAsString();
}
LLVM_DUMP_METHOD void Selector::dump() const { print(llvm::errs()); }
/// Interpreting the given string using the normal CamelCase
/// conventions, determine whether the given string starts with the
/// given "word", which is assumed to end in a lowercase letter.