Skip to content

Commit

Permalink
Merge Pull Request #13766 from trilinos/Trilinos/malachi/fix-rol-miss…
Browse files Browse the repository at this point in the history
…ing-switch

Automatically Merged using Trilinos Pull Request AutoTester
PR Title: b'ROL: Fix missing switch-case compilation error in OptimizationSolver'
PR Author: MalachiTimothyPhillips
  • Loading branch information
trilinos-autotester authored Feb 4, 2025
2 parents 5967723 + eaf8f13 commit f251642
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions cmake/ProjectCompilerPostConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@ set(promoted_warnings
sequence-point
sign-compare
strict-aliasing
switch
type-limits
uninitialized
unused-function
Expand Down
1 change: 1 addition & 0 deletions packages/rol/adapters/sacado/test/test_01.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,7 @@ int main(int argc, char *argv[]) {
break;

case TYPE_LAST:
default:
ROL_TEST_FOR_EXCEPTION(true,std::invalid_argument,"Error: Unsupported problem type!");
break;
}
Expand Down
1 change: 1 addition & 0 deletions packages/rol/src/algorithm/ROL_OptimizationSolver.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -219,6 +219,7 @@ class OptimizationSolver {
output_ = algo_->run(*x_,*g_,*l_,*c_,*obj_,*con_,*bnd_,true,outStream);
break;
case TYPE_LAST:
default:
ROL_TEST_FOR_EXCEPTION(true,std::invalid_argument,
"Error in OptimizationSolver::solve() : Unsupported problem type");
}
Expand Down

0 comments on commit f251642

Please sign in to comment.