summaryrefslogtreecommitdiffstats
path: root/Source/CursesDialog/cmCursesOptionsWidget.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/CursesDialog/cmCursesOptionsWidget.cxx')
-rw-r--r--Source/CursesDialog/cmCursesOptionsWidget.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/CursesDialog/cmCursesOptionsWidget.cxx b/Source/CursesDialog/cmCursesOptionsWidget.cxx
index d26a98f..a8c4933 100644
--- a/Source/CursesDialog/cmCursesOptionsWidget.cxx
+++ b/Source/CursesDialog/cmCursesOptionsWidget.cxx
@@ -75,9 +75,8 @@ void cmCursesOptionsWidget::SetOption(const std::string& value)
this->CurrentOption = 0; // default to 0 index
this->SetValue(value);
int index = 0;
- for (std::vector<std::string>::iterator i = this->Options.begin();
- i != this->Options.end(); ++i) {
- if (*i == value) {
+ for (auto const& opt : this->Options) {
+ if (opt == value) {
this->CurrentOption = index;
}
index++;