@@ -805,14 +805,18 @@ class ExecutionTest {
805805 const char *pShaderModelStr, const char *pShader,
806806 Ty *pInputDataPairs, unsigned inputDataCount);
807807
808- template <typename T, std::size_t N>
809- //typename = std::enable_if_t<std::is_arithmetic_v<T>>>
808+ template <typename T, std::size_t N,
809+ typename = std::enable_if_t<std::is_arithmetic_v<T>>>
810+ // By checking that T is an arithmetic we can keep the compiler error messages
811+ // from misusing the template much cleaner.
810812 void LongVectorBinaryOpTestBase();
811813 template <typename T>
812814 void LongVectorBinaryOpTestBase();
813815
814- template <typename T, std::size_t N>
815- //typename = std::enable_if_t<std::is_arithmetic_v<T>>>
816+ template <typename T, std::size_t N,
817+ typename = std::enable_if_t<std::is_arithmetic_v<T>>>
818+ // By checking that T is an arithmetic we can keep the compiler error messages
819+ // from misusing the template much cleaner.
816820 void LongVectorUnaryOpTestBase();
817821 template <typename T>
818822 void LongVectorUnaryOpTestBase();
@@ -11229,7 +11233,9 @@ TEST_F(ExecutionTest, PackUnpackTest) {
1122911233// before checking in PR.
1123011234// SLongVectorBinaryOp is used in ShaderOpArithTable.xml. The shader program
1123111235// uses the struct defintion to read from the input global buffer.
11232- template <typename T, std::size_t N = 4,
11236+ template <typename T, std::size_t N,
11237+ // By checking that T is an arithmetic we can keep the compiler error messages
11238+ // from misusing the template much cleaner.
1123311239typename = std::enable_if_t<std::is_arithmetic_v<T>>>
1123411240struct SLongVectorBinaryOp {
1123511241 T scalarInput;
@@ -11668,8 +11674,10 @@ void ExecutionTest::LongVectorUnaryOpTestBase() {
1166811674 LongVectorUnaryOpTestBase<T, 1024>();
1166911675}
1167011676
11671- template <typename T, std::size_t N>
11672- //typename = std::enable_if_t<std::is_arithmetic_v<T>>>
11677+ template <typename T, std::size_t N,
11678+ // By checking that T is an arithmetic we can keep the compiler error messages
11679+ // from misusing the template much cleaner.
11680+ typename = std::enable_if_t<std::is_arithmetic_v<T>>>
1167311681void ExecutionTest::LongVectorUnaryOpTestBase() {
1167411682 WEX::TestExecution::SetVerifyOutput verifySettings(
1167511683 WEX::TestExecution::VerifyOutputSettings::LogOnlyFailures);
0 commit comments