| 82 | // conversion explicit. |
| 83 | template<typename Ti, typename To> |
| 84 | void cast_test_complex_real() { |
| 85 | SUPPORTED_TYPE_CHECK(Ti); |
| 86 | SUPPORTED_TYPE_CHECK(To); |
| 87 | |
| 88 | af_dtype ta = (af_dtype)dtype_traits<Ti>::af_type; |
| 89 | af_dtype tb = (af_dtype)dtype_traits<To>::af_type; |
| 90 | dim4 dims(num, 1, 1, 1); |
| 91 | af_array a, b; |
| 92 | af_randu(&a, dims.ndims(), dims.get(), ta); |
| 93 | af_err err = af_cast(&b, a, tb); |
| 94 | ASSERT_EQ(err, AF_ERR_TYPE); |
| 95 | ASSERT_SUCCESS(af_release_array(a)); |
| 96 | } |
| 97 | |
| 98 | #define COMPLEX_REAL_TESTS(Ti, To) \ |
| 99 | TEST(CAST_TEST, Test_Complex_To_Real_##Ti##_##To) { \ |
nothing calls this directly
no test coverage detected