@@ -32,7 +32,7 @@ use crate::iter::{
32
32
AxisChunksIter , AxisChunksIterMut , AxisIter , AxisIterMut , ExactChunks , ExactChunksMut ,
33
33
IndexedIter , IndexedIterMut , Iter , IterMut , Lanes , LanesMut , Windows ,
34
34
} ;
35
- use crate :: slice:: { CanSlice , MultiSlice } ;
35
+ use crate :: slice:: { MultiSlice , SliceArg } ;
36
36
use crate :: stacking:: concatenate;
37
37
use crate :: { AxisSliceInfo , NdIndex , Slice } ;
38
38
@@ -334,16 +334,13 @@ where
334
334
/// Return a sliced view of the array.
335
335
///
336
336
/// See [*Slicing*](#slicing) for full documentation.
337
- /// See also [`SliceInfo`] and [`D::SliceArg`].
338
- ///
339
- /// [`SliceInfo`]: struct.SliceInfo.html
340
- /// [`D::SliceArg`]: trait.Dimension.html#associatedtype.SliceArg
337
+ /// See also [`s!`], [`SliceArg`], and [`SliceInfo`](crate::SliceInfo).
341
338
///
342
339
/// **Panics** if an index is out of bounds or step size is zero.<br>
343
340
/// (**Panics** if `D` is `IxDyn` and `info` does not match the number of array axes.)
344
341
pub fn slice < I > ( & self , info : & I ) -> ArrayView < ' _ , A , I :: OutDim >
345
342
where
346
- I : CanSlice < D > + ?Sized ,
343
+ I : SliceArg < D > + ?Sized ,
347
344
S : Data ,
348
345
{
349
346
self . view ( ) . slice_move ( info)
@@ -352,16 +349,13 @@ where
352
349
/// Return a sliced read-write view of the array.
353
350
///
354
351
/// See [*Slicing*](#slicing) for full documentation.
355
- /// See also [`SliceInfo`] and [`D::SliceArg`].
356
- ///
357
- /// [`SliceInfo`]: struct.SliceInfo.html
358
- /// [`D::SliceArg`]: trait.Dimension.html#associatedtype.SliceArg
352
+ /// See also [`s!`], [`SliceArg`], and [`SliceInfo`](crate::SliceInfo).
359
353
///
360
354
/// **Panics** if an index is out of bounds or step size is zero.<br>
361
355
/// (**Panics** if `D` is `IxDyn` and `info` does not match the number of array axes.)
362
356
pub fn slice_mut < I > ( & mut self , info : & I ) -> ArrayViewMut < ' _ , A , I :: OutDim >
363
357
where
364
- I : CanSlice < D > + ?Sized ,
358
+ I : SliceArg < D > + ?Sized ,
365
359
S : DataMut ,
366
360
{
367
361
self . view_mut ( ) . slice_move ( info)
@@ -370,10 +364,7 @@ where
370
364
/// Return multiple disjoint, sliced, mutable views of the array.
371
365
///
372
366
/// See [*Slicing*](#slicing) for full documentation.
373
- /// See also [`SliceInfo`] and [`D::SliceArg`].
374
- ///
375
- /// [`SliceInfo`]: struct.SliceInfo.html
376
- /// [`D::SliceArg`]: trait.Dimension.html#associatedtype.SliceArg
367
+ /// See also [`s!`], [`SliceArg`], and [`SliceInfo`](crate::SliceInfo).
377
368
///
378
369
/// **Panics** if any of the following occur:
379
370
///
@@ -403,16 +394,13 @@ where
403
394
/// Slice the array, possibly changing the number of dimensions.
404
395
///
405
396
/// See [*Slicing*](#slicing) for full documentation.
406
- /// See also [`SliceInfo`] and [`D::SliceArg`].
407
- ///
408
- /// [`SliceInfo`]: struct.SliceInfo.html
409
- /// [`D::SliceArg`]: trait.Dimension.html#associatedtype.SliceArg
397
+ /// See also [`s!`], [`SliceArg`], and [`SliceInfo`](crate::SliceInfo).
410
398
///
411
399
/// **Panics** if an index is out of bounds or step size is zero.<br>
412
400
/// (**Panics** if `D` is `IxDyn` and `info` does not match the number of array axes.)
413
401
pub fn slice_move < I > ( mut self , info : & I ) -> ArrayBase < S , I :: OutDim >
414
402
where
415
- I : CanSlice < D > + ?Sized ,
403
+ I : SliceArg < D > + ?Sized ,
416
404
{
417
405
assert_eq ! (
418
406
info. in_ndim( ) ,
@@ -462,6 +450,7 @@ where
462
450
/// Slice the array in place without changing the number of dimensions.
463
451
///
464
452
/// See [*Slicing*](#slicing) for full documentation.
453
+ /// See also [`s!`], [`SliceArg`], and [`SliceInfo`](crate::SliceInfo).
465
454
///
466
455
/// **Panics** in the following cases:
467
456
///
@@ -472,7 +461,7 @@ where
472
461
/// - if `D` is `IxDyn` and `info` does not match the number of array axes
473
462
pub fn slice_collapse < I > ( & mut self , info : & I )
474
463
where
475
- I : CanSlice < D > + ?Sized ,
464
+ I : SliceArg < D > + ?Sized ,
476
465
{
477
466
assert_eq ! (
478
467
info. in_ndim( ) ,
0 commit comments