diff options
author | Reid Kleckner <reid@kleckner.net> | 2014-06-19 01:23:22 +0000 |
---|---|---|
committer | Reid Kleckner <reid@kleckner.net> | 2014-06-19 01:23:22 +0000 |
commit | c05ca5e40c7eee09a12fe5fff81e7ca1b3450aba (patch) | |
tree | 6a40da951b71e076748c68424d2dee728e4c769a /clang/lib/Sema/SemaDecl.cpp | |
parent | a0050b0961b1fd1cbdd58bc6257bc3f54b25acf4 (diff) | |
download | bcm5719-llvm-c05ca5e40c7eee09a12fe5fff81e7ca1b3450aba.tar.gz bcm5719-llvm-c05ca5e40c7eee09a12fe5fff81e7ca1b3450aba.zip |
DiagnoseUnknownTypename always emits a diagnostic and returns true
Make it return void and delete the dead code in the parser that handled
the case where it might return false. This has been dead since 2010
when John deleted Action.h.
llvm-svn: 211248
Diffstat (limited to 'clang/lib/Sema/SemaDecl.cpp')
-rw-r--r-- | clang/lib/Sema/SemaDecl.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/clang/lib/Sema/SemaDecl.cpp b/clang/lib/Sema/SemaDecl.cpp index d4c3cf2d066..e4b2096bec7 100644 --- a/clang/lib/Sema/SemaDecl.cpp +++ b/clang/lib/Sema/SemaDecl.cpp @@ -438,7 +438,7 @@ bool Sema::isMicrosoftMissingTypename(const CXXScopeSpec *SS, Scope *S) { return CurContext->isFunctionOrMethod() || S->isFunctionPrototypeScope(); } -bool Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II, +void Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II, SourceLocation IILoc, Scope *S, CXXScopeSpec *SS, @@ -483,7 +483,7 @@ bool Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II, /*IsCtorOrDtorName=*/false, /*NonTrivialTypeSourceInfo=*/true); } - return true; + return; } if (getLangOpts().CPlusPlus) { @@ -502,7 +502,7 @@ bool Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II, Diag(TplDecl->getLocation(), diag::note_template_decl_here) << TplDecl->getTemplateParameters()->getSourceRange(); } - return true; + return; } } @@ -529,8 +529,6 @@ bool Sema::DiagnoseUnknownTypeName(IdentifierInfo *&II, assert(SS && SS->isInvalid() && "Invalid scope specifier has already been diagnosed"); } - - return true; } /// \brief Determine whether the given result set contains either a type name |