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 | c48affb81f979a9eb554208bd63a978228928b4c (patch) | |
| tree | 3ffbddbdd1260366c7914e31a1be99afc1ee4d49 /clang/Sema/SemaStmt.cpp | |
| parent | 676070d5039b56e56327ec51fd7436abdb071281 (diff) | |
| download | bcm5719-llvm-c48affb81f979a9eb554208bd63a978228928b4c.tar.gz bcm5719-llvm-c48affb81f979a9eb554208bd63a978228928b4c.zip | |
Removed dead variable "hadError" in ParseReturnStmt.
llvm-svn: 41079
Diffstat (limited to 'clang/Sema/SemaStmt.cpp')
| -rw-r--r-- | clang/Sema/SemaStmt.cpp | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/clang/Sema/SemaStmt.cpp b/clang/Sema/SemaStmt.cpp index 39e3b89919c..b3a1f1c42cb 100644 --- a/clang/Sema/SemaStmt.cpp +++ b/clang/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) |

