diff options
author | Dan Gohman <gohman@apple.com> | 2009-04-20 16:19:02 +0000 |
---|---|---|
committer | Dan Gohman <gohman@apple.com> | 2009-04-20 16:19:02 +0000 |
commit | 51747a7e51d4e567d55b1bdb7b7d6a193dc9ea5a (patch) | |
tree | fb516a03ed8e6d32af1f8b5465608148970a4144 | |
parent | ba0941fbe0db832b0bdca450688b63ddf6a45b0a (diff) |
Use .empty() instead of .size().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@69599 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | tools/llvm-extract/llvm-extract.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/llvm-extract/llvm-extract.cpp b/tools/llvm-extract/llvm-extract.cpp index 014d231a29..46840f2e22 100644 --- a/tools/llvm-extract/llvm-extract.cpp +++ b/tools/llvm-extract/llvm-extract.cpp @@ -81,11 +81,11 @@ int main(int argc, char **argv) { } // Figure out which function we should extract - GlobalVariable *G = ExtractGlobal.size() ? + GlobalVariable *G = !ExtractGlobal.empty() ? M.get()->getNamedGlobal(ExtractGlobal) : 0; // Figure out which function we should extract - if (!ExtractFunc.size() && !ExtractGlobal.size()) ExtractFunc = "main"; + if (ExtractFunc.empty() && ExtractGlobal.empty()) ExtractFunc = "main"; Function *F = M.get()->getFunction(ExtractFunc); if (F == 0 && G == 0) { |