diff options
author | Brad King <brad.king@kitware.com> | 2019-02-13 15:16:23 (GMT) |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-02-13 15:16:31 (GMT) |
commit | 264128469df1460c60099a3321b80cedcf8d2d26 (patch) | |
tree | 61c1eced98a5fdf47375fee93159c2a06b656257 | |
parent | 21853e247c6b18df4e691cf29855ede3bbcce28e (diff) | |
parent | c28abdb5aceac3fdf9383b0ee464d3578fbb86b3 (diff) | |
download | CMake-264128469df1460c60099a3321b80cedcf8d2d26.zip CMake-264128469df1460c60099a3321b80cedcf8d2d26.tar.gz CMake-264128469df1460c60099a3321b80cedcf8d2d26.tar.bz2 |
Merge topic 'cmcurses-fix-solaris-lambda-warning'
c28abdb5ac cmCursesMainForm: Fix lambda return type deducing warning
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2955
-rw-r--r-- | Source/CursesDialog/cmCursesMainForm.cxx | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/Source/CursesDialog/cmCursesMainForm.cxx b/Source/CursesDialog/cmCursesMainForm.cxx index 3fe1834..906dd02 100644 --- a/Source/CursesDialog/cmCursesMainForm.cxx +++ b/Source/CursesDialog/cmCursesMainForm.cxx @@ -647,11 +647,12 @@ void cmCursesMainForm::RemoveEntry(const char* value) return; } - auto removeIt = std::find_if(this->Entries->begin(), this->Entries->end(), - [value](cmCursesCacheEntryComposite* entry) { - const char* val = entry->GetValue(); - return val && !strcmp(value, val); - }); + auto removeIt = + std::find_if(this->Entries->begin(), this->Entries->end(), + [value](cmCursesCacheEntryComposite* entry) -> bool { + const char* val = entry->GetValue(); + return val != nullptr && !strcmp(value, val); + }); if (removeIt != this->Entries->end()) { this->CMakeInstance->UnwatchUnusedCli(value); |