Skip to content

Commit 13f3ec1

Browse files
author
The ml_dtypes Authors
committed
Merge pull request #356 from seberg:complex-fixup-assert
PiperOrigin-RevId: 865993892
2 parents bc96f52 + 60182cd commit 13f3ec1

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ml_dtypes/_src/custom_complex.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -714,7 +714,7 @@ void NPyCCast(void* from_void, void* to_void, npy_intp n, void* fromarr,
714714
auto via = static_cast<float>(from[i]);
715715
to[i] = static_cast<typename TypeDescriptor<To>::T>(via);
716716
} else {
717-
static_assert(0);
717+
static_assert(is_complex_v<From>); // template dependent, always false
718718
}
719719
}
720720
}

0 commit comments

Comments
 (0)