Skip to content

Commit 0b27b49

Browse files
committed
fix type qualification for slice
1 parent 2fce216 commit 0b27b49

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

source/mir/ndslice/allocation.d

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,8 @@ auto slice(SliceKind kind, size_t[] packs, Iterator)(Slice!(kind, packs, Iterato
8787
alias fun = .uninitSlice;
8888
auto ret = fun!T(slice.shape);
8989
ret[] = slice;
90-
return ret;
90+
auto retq = ()@trusted{ return (cast(slice.DeepElemType*)ret._iterator).sliced(ret.shape); }();
91+
return retq;
9192
}
9293

9394
///

0 commit comments

Comments
 (0)