diff --git a/libs/core/program_options/src/value_semantic.cpp b/libs/core/program_options/src/value_semantic.cpp index ff991b4c52a7..c11f4bde1bc7 100644 --- a/libs/core/program_options/src/value_semantic.cpp +++ b/libs/core/program_options/src/value_semantic.cpp @@ -379,8 +379,9 @@ namespace hpx::program_options { std::string error_template = original_error_template; // remove duplicates using std::set - std::set alternatives_set(m_alternatives.begin(), m_alternatives.end()); - std::vector const alternatives_vec( + std::set alternatives_set( + m_alternatives.begin(), m_alternatives.end()); + std::vector const alternatives_vec( alternatives_set.begin(), alternatives_set.end()); error_template += " and matches ";