Skip to content

Commit 8415380

Browse files
committed
Auto-generated commit
1 parent 5e123c1 commit 8415380

5 files changed

Lines changed: 9 additions & 8 deletions

File tree

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,9 @@
3333

3434
<details>
3535

36+
- [`a9e03ed`](https://github.com/stdlib-js/stdlib/commit/a9e03edc48bf43a1c290ed1ec1e2f69186678b15) - **refactor:** add missing generic type-parameter defaults in `ndarray` reverse declarations [(#12666)](https://github.com/stdlib-js/stdlib/pull/12666) _(by Philipp Burckhardt)_
37+
- [`d01cc15`](https://github.com/stdlib-js/stdlib/commit/d01cc150c5d271c5132af9706f86fd15160e5f39) - **docs:** update `ndarray` TypeScript declarations [(#12662)](https://github.com/stdlib-js/stdlib/pull/12662) _(by stdlib-bot)_
38+
- [`69a4924`](https://github.com/stdlib-js/stdlib/commit/69a49243032c5e1a845cba2f895c835a49368b77) - **docs:** update `ndarray/iter` TypeScript declarations [(#12661)](https://github.com/stdlib-js/stdlib/pull/12661) _(by stdlib-bot)_
3639
- [`02ceb9e`](https://github.com/stdlib-js/stdlib/commit/02ceb9ef7c4b0b987a79f07daa750ea9c18f3159) - **docs:** update `ndarray/base` TypeScript declarations [(#12660)](https://github.com/stdlib-js/stdlib/pull/12660) _(by stdlib-bot)_
3740
- [`cd863cf`](https://github.com/stdlib-js/stdlib/commit/cd863cfcc93259fc77714263c6c8b532c84563a3) - **docs:** propagate recent develop fixes to sibling packages [(#12642)](https://github.com/stdlib-js/stdlib/pull/12642) _(by Philipp Burckhardt)_
3841
- [`4e89875`](https://github.com/stdlib-js/stdlib/commit/4e898755cf98f6e3b8d8c24079fb9ea7730f2d9c) - **fix:** preserve input ndarray type in `ndarray/base/maybe-broadcast-array-except-dimensions` [(#12629)](https://github.com/stdlib-js/stdlib/pull/12629) _(by Philipp Burckhardt, Athan Reines)_

base/reverse/docs/types/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ import { ndarray } from '@stdlib/types/ndarray';
5151
* sh = getShape( y );
5252
* // returns [ 3, 2 ]
5353
*/
54-
declare function reverse<T extends ndarray>( x: T, writable: boolean ): T;
54+
declare function reverse<T extends ndarray = ndarray>( x: T, writable: boolean ): T;
5555

5656

5757
// EXPORTS //

docs/types/index.d.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -310,7 +310,7 @@ interface Namespace {
310310
* @param options.flatten - boolean indicating whether to automatically flatten generic array data sources (default: true)
311311
* @param options.ndmin - minimum number of dimensions (default: 0)
312312
* @param options.casting - casting rule used to determine what constitutes an acceptable cast (default: 'safe')
313-
* @param options.readonly - boolean indicating whether an array should be read-only
313+
* @param options.readonly - boolean indicating whether an array should be read-only (default: false)
314314
* @throws must provide valid options
315315
* @throws must provide either an array shape, data source, or both
316316
* @throws invalid cast
@@ -680,7 +680,6 @@ interface Namespace {
680680
*
681681
* @example
682682
* var array = require( './../../array' );
683-
* var ndarray2array = require( './../../to-array' );
684683
*
685684
* var x = array( [ -1.0, 2.0, 3.0, 4.0 ] );
686685
* var y = array( [ -5.0, 6.0, -7.0, -8.0, 9.0, -10.0 ] );
@@ -691,7 +690,6 @@ interface Namespace {
691690
* @example
692691
* var array = require( './../../array' );
693692
* var empty = require( './../../empty' );
694-
* var ndarray2array = require( './../../to-array' );
695693
*
696694
* var x = array( [ -1.0, 2.0, 3.0, 4.0 ] );
697695
* var y = array( [ -5.0, 6.0, -7.0, -8.0, 9.0, -10.0 ] );
@@ -2413,7 +2411,7 @@ interface Namespace {
24132411
*
24142412
* ## Notes
24152413
*
2416-
* - The function throws an error if a provided broadcast-incompatible ndarrays.
2414+
* - The function throws an error if provided broadcast-incompatible ndarrays.
24172415
* - If a provided ndarray has a shape matching the common shape, the function returns the provided ndarray.
24182416
* - If a provided ndarray has a different (broadcast compatible) shape than the common shape, the function returns a new **read-only** ndarray view of the provided ndarray's data. The view is typically **not** contiguous. As more than one element of a returned view may refer to the same memory location, writing to a view may affect multiple elements. If you need to write to an input array, copy the array before broadcasting.
24192417
*

iter/docs/types/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -188,7 +188,7 @@ interface Namespace {
188188
*
189189
* ## Notes
190190
*
191-
* - The function throws an error if a provided broadcast-incompatible ndarrays.
191+
* - The function throws an error if provided broadcast-incompatible ndarrays.
192192
* - For input ndarrays supporting read-only views, the function returns *read-only* views of interleaved subarrays. As input ndarrays may be broadcasted, a view is typically *not* contiguous. As more than one element of a returned view may refer to the same memory location, writing to a view may affect multiple elements. If you need to write to a subarray, copy the subarray before attempting mutation.
193193
*
194194
* @param arr - input ndarrays

to-reversed-dimension/docs/types/index.d.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ interface Options {
3838
* @param x - input array
3939
* @param options - function options
4040
* @param options.dim - index of dimension to reverse
41-
* @returns output array
41+
* @returns output ndarray
4242
*
4343
* @example
4444
* var array = require( '@stdlib/ndarray/array' );
@@ -49,7 +49,7 @@ interface Options {
4949
* var y = toReversedDimension( x );
5050
* // returns <ndarray>[ [ 2.0, 1.0 ], [ 4.0, 3.0 ] ]
5151
*/
52-
declare function toReversedDimension<T extends ndarray>( x: T, options?: Options ): T;
52+
declare function toReversedDimension<T extends ndarray = ndarray>( x: T, options?: Options ): T;
5353

5454

5555
// EXPORTS //

0 commit comments

Comments
 (0)