diff options
author | Ted Kremenek <kremenek@apple.com> | 2007-08-14 18:14:14 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2007-08-14 18:14:14 +0000 |
commit | 6a2394c4eaa87580f44f49205e5ca8aba628bdd8 (patch) | |
tree | eb8c3ddf24a65129da1a913e6cad2bad41928d4c | |
parent | 71895b9aa3ad71957359497e136b50fcb6136bdf (diff) |
Removed dead variable "hadError" in ParseReturnStmt.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@41079 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | Sema/SemaStmt.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Sema/SemaStmt.cpp b/Sema/SemaStmt.cpp index 39e3b89919..b3a1f1c42c 100644 --- a/Sema/SemaStmt.cpp +++ b/Sema/SemaStmt.cpp @@ -324,8 +324,7 @@ Sema::ParseReturnStmt(SourceLocation ReturnLoc, ExprTy *rex) { // function return. AssignmentCheckResult result = CheckSingleAssignmentConstraints(lhsType, RetValExp); - bool hadError = false; - + // decode the result (notice that extensions still return a type). switch (result) { case Compatible: @@ -334,7 +333,6 @@ Sema::ParseReturnStmt(SourceLocation ReturnLoc, ExprTy *rex) { Diag(ReturnLoc, diag::err_typecheck_return_incompatible, lhsType.getAsString(), rhsType.getAsString(), RetValExp->getSourceRange()); - hadError = true; break; case PointerFromInt: // check for null pointer constant (C99 6.3.2.3p3) |