not sure if there is a difference but the rest of the file uses `isComplexType(x.dtype.type)` so its better to use it here too.