Skip to content

Commit caf5124

Browse files
committed
Fix nvc++ compilation error when using a constexpr std::array of size 3 (an error that should NOT happen!).
1 parent 35f25a4 commit caf5124

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

tests/types_to_test.hpp

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -498,9 +498,16 @@ constexpr std::array<plssvm::classification_type, 2> classification_types_to_tes
498498
plssvm::classification_type::oaa, plssvm::classification_type::oao
499499
};
500500
/// A list of all available solver types.
501-
constexpr std::array<plssvm::solver_type, 3> solver_types_to_test{
502-
plssvm::solver_type::automatic, plssvm::solver_type::cg_explicit, plssvm::solver_type::cg_implicit
503-
};
501+
constexpr std::array<plssvm::solver_type,
502+
#if defined(__NVCOMPILER) // TODO: fixes nvc++ compilation error, that SHOULD NOT be there in the first place
503+
4
504+
#else
505+
3
506+
#endif
507+
>
508+
solver_types_to_test{
509+
plssvm::solver_type::automatic, plssvm::solver_type::cg_explicit, plssvm::solver_type::cg_implicit
510+
};
504511

505512
/// A list of all solver types.
506513
using solver_type_list = cartesian_value_product_t<solver_types_to_test>;

0 commit comments

Comments
 (0)