[cfe-commits] r66014 - /cfe/trunk/include/clang/AST/Stmt.h
Chris Lattner
sabre at nondot.org
Tue Mar 3 20:30:03 PST 2009
Author: lattner
Date: Tue Mar 3 22:30:02 2009
New Revision: 66014
URL: http://llvm.org/viewvc/llvm-project?rev=66014&view=rev
Log:
fix infinite recursion
Modified:
cfe/trunk/include/clang/AST/Stmt.h
Modified: cfe/trunk/include/clang/AST/Stmt.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/AST/Stmt.h?rev=66014&r1=66013&r2=66014&view=diff
==============================================================================
--- cfe/trunk/include/clang/AST/Stmt.h (original)
+++ cfe/trunk/include/clang/AST/Stmt.h Tue Mar 3 22:30:02 2009
@@ -471,7 +471,7 @@
virtual SourceRange getSourceRange() const {
// Handle deeply nested case statements with iteration instead of recursion.
const CaseStmt *CS = this;
- while (const CaseStmt *CS2 = dyn_cast<CaseStmt>(getSubStmt()))
+ while (const CaseStmt *CS2 = dyn_cast<CaseStmt>(CS->getSubStmt()))
CS = CS2;
return SourceRange(CaseLoc, CS->getSubStmt()->getLocEnd());
More information about the cfe-commits
mailing list