@@ -4,7 +4,11 @@ Version 0.15.0 (Not released yet)
44New features
55------------
66
7- - Support inserting new axes while slicing by [ @jturner314 ]
7+ - Support inserting new axes while slicing by [ @jturner314 ] . This is an example:
8+
9+ ``` rust
10+ let view = arr . slice (s! [.. , - 1 , 2 .. ;- 1 , NewAxis ]);
11+ ```
812
913 https://github.com/rust-ndarray/ndarray/pull/570
1014
@@ -72,6 +76,30 @@ Enhancements
7276API changes
7377-----------
7478
79+ - Changes to the slicing-related types and macro by [ @jturner314 ] and [ @bluss ] :
80+
81+ - Remove the ` Dimension::SliceArg ` associated type, and add a new ` SliceArg `
82+ trait for this purpose.
83+ - Change the return type of the ` s![] ` macro to an owned ` SliceInfo ` rather
84+ than a reference.
85+ - Replace the ` SliceOrIndex ` enum with ` SliceInfoElem ` , which has an
86+ additional ` NewAxis ` variant and does not have a ` step_by ` method.
87+ - Change the type parameters of ` SliceInfo ` in order to support the ` NewAxis `
88+ functionality and remove some tricky ` unsafe ` code.
89+ - Mark the ` SliceInfo::new ` method as ` unsafe ` . The new implementations of
90+ ` TryFrom ` can be used as a safe alternative.
91+ - Remove the ` AsRef<SliceInfo<[SliceOrIndex], D>> for SliceInfo<T, D> `
92+ implementation. Add the similar `From<&'a SliceInfo<T, Din, Dout>> for
93+ SliceInfo<&'a [ SliceInfoElem] , Din, Dout>` conversion as an alternative.
94+ - Change the * expr* ` ; ` * step* case in the ` s![] ` macro to error at compile
95+ time if an unsupported type for * expr* is used, instead of panicking at
96+ runtime.
97+
98+ https://github.com/rust-ndarray/ndarray/pull/570 <br >
99+ https://github.com/rust-ndarray/ndarray/pull/940 <br >
100+ https://github.com/rust-ndarray/ndarray/pull/943 <br >
101+ https://github.com/rust-ndarray/ndarray/pull/945 <br >
102+
75103- Removed already deprecated methods by [ @bluss ] :
76104
77105 - Remove deprecated ` .all_close() ` - use approx feature and methods like ` .abs_diff_eq ` instead
@@ -142,6 +170,12 @@ Bug fixes
142170
143171 https://github.com/rust-ndarray/ndarray/pull/855
144172
173+ - Mark the ` SliceInfo::new ` method as ` unsafe ` due to the requirement that
174+ ` indices.as_ref() ` always return the same value when called multiple times,
175+ by [ @bluss ] and [ @jturner314 ]
176+
177+ https://github.com/rust-ndarray/ndarray/pull/570
178+
145179Other changes
146180-------------
147181
0 commit comments