mirror of
https://github.com/ml-explore/mlx.git
synced 2025-06-25 01:41:17 +08:00
0ul is not size_t on MSVC (#1762)
This commit is contained in:
parent
1ce0c0fcb0
commit
ab8e832c18
@ -824,7 +824,7 @@ array slice_update(
|
|||||||
|
|
||||||
// Broadcast update with unspecified axes
|
// Broadcast update with unspecified axes
|
||||||
auto up_shape = update.shape();
|
auto up_shape = update.shape();
|
||||||
auto dim_diff = std::max(src.ndim() - update.ndim(), 0ul);
|
auto dim_diff = std::max(src.ndim() - update.ndim(), size_t(0));
|
||||||
up_shape.insert(
|
up_shape.insert(
|
||||||
up_shape.begin(), src.shape().begin(), src.shape().begin() + dim_diff);
|
up_shape.begin(), src.shape().begin(), src.shape().begin() + dim_diff);
|
||||||
for (int d = dim_diff; d < src.ndim(); ++d) {
|
for (int d = dim_diff; d < src.ndim(); ++d) {
|
||||||
|
Loading…
Reference in New Issue
Block a user