[cfe-commits] r84342 - /cfe/trunk/lib/Analysis/CFRefCount.cpp
Daniel Dunbar
daniel at zuster.org
Sat Oct 17 11:12:55 PDT 2009
Author: ddunbar
Date: Sat Oct 17 13:12:53 2009
New Revision: 84342
URL: http://llvm.org/viewvc/llvm-project?rev=84342&view=rev
Log:
Simplify more.
Modified:
cfe/trunk/lib/Analysis/CFRefCount.cpp
Modified: cfe/trunk/lib/Analysis/CFRefCount.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/CFRefCount.cpp?rev=84342&r1=84341&r2=84342&view=diff
==============================================================================
--- cfe/trunk/lib/Analysis/CFRefCount.cpp (original)
+++ cfe/trunk/lib/Analysis/CFRefCount.cpp Sat Oct 17 13:12:53 2009
@@ -212,16 +212,12 @@
ASTContext* Ctx = 0, const char* name = 0) {
// Recursively walk the typedef stack, allowing typedefs of reference types.
- while (1) {
- if (TypedefType* TD = dyn_cast<TypedefType>(RetTy.getTypePtr())) {
- llvm::StringRef TDName = TD->getDecl()->getIdentifier()->getNameStr();
- if (TDName.startswith(prefix) && TDName.endswith("Ref"))
- return true;
+ while (TypedefType* TD = dyn_cast<TypedefType>(RetTy.getTypePtr())) {
+ llvm::StringRef TDName = TD->getDecl()->getIdentifier()->getNameStr();
+ if (TDName.startswith(prefix) && TDName.endswith("Ref"))
+ return true;
- RetTy = TD->getDecl()->getUnderlyingType();
- continue;
- }
- break;
+ RetTy = TD->getDecl()->getUnderlyingType();
}
if (!Ctx || !name)
More information about the cfe-commits
mailing list