mirror of
https://github.com/ml-explore/mlx.git
synced 2025-12-16 01:49:05 +08:00
feat: metal formatting and pre-commit bump (#1038)
* feat: metal formatting and pre-commit bump * add guards * update * more guards * more guards * smakk fix * Refactor instantiation of ternary types in ternary.metal * fix scan.metal
This commit is contained in:
@@ -14,8 +14,8 @@ inline constexpr bool can_convert_to_complex128 =
|
||||
!std::is_same_v<T, complex128_t> && std::is_convertible_v<T, double>;
|
||||
|
||||
struct complex128_t : public std::complex<double> {
|
||||
complex128_t(double v, double u) : std::complex<double>(v, u){};
|
||||
complex128_t(std::complex<double> v) : std::complex<double>(v){};
|
||||
complex128_t(double v, double u) : std::complex<double>(v, u) {};
|
||||
complex128_t(std::complex<double> v) : std::complex<double>(v) {};
|
||||
|
||||
template <
|
||||
typename T,
|
||||
@@ -32,8 +32,8 @@ inline constexpr bool can_convert_to_complex64 =
|
||||
!std::is_same_v<T, complex64_t> && std::is_convertible_v<T, float>;
|
||||
|
||||
struct complex64_t : public std::complex<float> {
|
||||
complex64_t(float v, float u) : std::complex<float>(v, u){};
|
||||
complex64_t(std::complex<float> v) : std::complex<float>(v){};
|
||||
complex64_t(float v, float u) : std::complex<float>(v, u) {};
|
||||
complex64_t(std::complex<float> v) : std::complex<float>(v) {};
|
||||
|
||||
template <
|
||||
typename T,
|
||||
|
||||
Reference in New Issue
Block a user