diff options
author | Reid Kleckner <reid@kleckner.net> | 2014-06-11 21:57:15 +0000 |
---|---|---|
committer | Reid Kleckner <reid@kleckner.net> | 2014-06-11 21:57:15 +0000 |
commit | 7e8fd6b3112f355cfa38d211b999556eb8c05eed (patch) | |
tree | df8e36fb90088db19dd68cad44b4738031bddef3 /lib/Sema/SemaExpr.cpp | |
parent | 137f71e5c172937c75a24d456739e4b9188bacff (diff) | |
download | clang-7e8fd6b3112f355cfa38d211b999556eb8c05eed.tar.gz clang-7e8fd6b3112f355cfa38d211b999556eb8c05eed.tar.bz2 clang-7e8fd6b3112f355cfa38d211b999556eb8c05eed.tar.xz |
Don't slice SemaDiagnosticBuilder
I wasn't able to figure out how to emit this diagnostic from a SFINAE
context, so I don't have a test.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@210713 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaExpr.cpp')
-rw-r--r-- | lib/Sema/SemaExpr.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/Sema/SemaExpr.cpp b/lib/Sema/SemaExpr.cpp index 408a8a4089..7c076f8e84 100644 --- a/lib/Sema/SemaExpr.cpp +++ b/lib/Sema/SemaExpr.cpp @@ -1952,9 +1952,8 @@ recoverFromMSUnqualifiedLookup(Sema &S, ASTContext &Context, // Diagnose this as unqualified lookup into a dependent base class. If 'this' // is available, suggest inserting 'this->' as a fixit. SourceLocation Loc = NameInfo.getLoc(); - DiagnosticBuilder DB = - S.Diag(Loc, diag::ext_undeclared_unqual_id_with_dependent_base) - << NameInfo.getName() << RD; + auto DB = S.Diag(Loc, diag::ext_undeclared_unqual_id_with_dependent_base); + DB << NameInfo.getName() << RD; if (!ThisType.isNull()) { DB << FixItHint::CreateInsertion(Loc, "this->"); |