diff --git a/array_api_strict/_elementwise_functions.py b/array_api_strict/_elementwise_functions.py index 10c854e..dfd8960 100644 --- a/array_api_strict/_elementwise_functions.py +++ b/array_api_strict/_elementwise_functions.py @@ -278,8 +278,8 @@ def clip( isinstance(arg, Array) and arg.dtype in _real_floating_dtypes)): raise TypeError(f"{argname} must be integral when x is integral") if (x.dtype in _real_floating_dtypes - and (isinstance(arg, int) or - isinstance(arg, Array) and arg.dtype in _integer_dtypes)): + and (isinstance(arg, Array) and arg.dtype in _integer_dtypes) + ): raise TypeError(f"{arg} must be floating-point when x is floating-point") # Normalize to make the below logic simpler