diff options
author | Nick Lewycky <nicholas@mxc.ca> | 2015-08-25 22:18:46 +0000 |
---|---|---|
committer | Nick Lewycky <nicholas@mxc.ca> | 2015-08-25 22:18:46 +0000 |
commit | 08426e2098aaab9b26bf236fe6ce9570e9ea3c4a (patch) | |
tree | 294e5d3830930947e85299fda9fe1ed902c528bc /clang/lib/Sema/SemaInit.cpp | |
parent | 73a7c93a0a55d5fea3c91dd5a21eb237eb7fddf0 (diff) | |
download | bcm5719-llvm-08426e2098aaab9b26bf236fe6ce9570e9ea3c4a.tar.gz bcm5719-llvm-08426e2098aaab9b26bf236fe6ce9570e9ea3c4a.zip |
Clarify the error message when the reason the conversion is not viable is because the returned value does not match the function return type.
llvm-svn: 245979
Diffstat (limited to 'clang/lib/Sema/SemaInit.cpp')
-rw-r--r-- | clang/lib/Sema/SemaInit.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/clang/lib/Sema/SemaInit.cpp b/clang/lib/Sema/SemaInit.cpp index 1b958ae782c..de11666747a 100644 --- a/clang/lib/Sema/SemaInit.cpp +++ b/clang/lib/Sema/SemaInit.cpp @@ -6946,6 +6946,7 @@ bool InitializationSequence::Diagnose(Sema &S, diag::err_typecheck_nonviable_condition_incomplete, Args[0]->getType(), Args[0]->getSourceRange())) S.Diag(Kind.getLocation(), diag::err_typecheck_nonviable_condition) + << (Entity.getKind() == InitializedEntity::EK_Result) << Args[0]->getType() << Args[0]->getSourceRange() << DestType.getNonReferenceType(); |