Skip to content

Commit 80f1150

Browse files
committed
Auto-generated commit
1 parent a96235e commit 80f1150

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686

8787
##### Features
8888

89+
- [`33b46cb`](https://github.com/stdlib-js/stdlib/commit/33b46cbab14e25a72a7464d6d923f09a56ee0d44) - update namespace TypeScript declarations [(#4426)](https://github.com/stdlib-js/stdlib/pull/4426)
8990
- [`1ddeba9`](https://github.com/stdlib-js/stdlib/commit/1ddeba98295bb53fb8098d1016f0de4b7f544e96) - add `scalar2ndarrayLike` to namespace
9091
- [`58e795d`](https://github.com/stdlib-js/stdlib/commit/58e795db467b7bd1d3dc6c5847f91a97fed2ccff) - update namespace TypeScript declarations [(#3937)](https://github.com/stdlib-js/stdlib/pull/3937)
9192
- [`14427c7`](https://github.com/stdlib-js/stdlib/commit/14427c79bc62f82b16cbadc9d34749901e48d105) - add `fill`, `map`, and `toReversed` to namespace
@@ -529,6 +530,7 @@ A total of 3 people contributed to this release. Thank you to the following cont
529530

530531
<details>
531532

533+
- [`33b46cb`](https://github.com/stdlib-js/stdlib/commit/33b46cbab14e25a72a7464d6d923f09a56ee0d44) - **feat:** update namespace TypeScript declarations [(#4426)](https://github.com/stdlib-js/stdlib/pull/4426) _(by stdlib-bot, Philipp Burckhardt)_
532534
- [`edae311`](https://github.com/stdlib-js/stdlib/commit/edae3110b4b7cc1d675d44e211ffffcff77d6153) - **docs:** update namespace table of contents [(#4428)](https://github.com/stdlib-js/stdlib/pull/4428) _(by stdlib-bot, Philipp Burckhardt)_
533535
- [`e4a53d5`](https://github.com/stdlib-js/stdlib/commit/e4a53d5816f5918f7c7fc5135dce21d676835eca) - **docs:** update related packages sections [(#4399)](https://github.com/stdlib-js/stdlib/pull/4399) _(by stdlib-bot)_
534536
- [`259b682`](https://github.com/stdlib-js/stdlib/commit/259b682b2fb67d03e2987ca02b57d0cbc631ae8e) - **feat:** add support for specifying an array index cache and add support for linear indexing _(by Athan Reines)_

base/docs/types/index.d.ts

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ import fliplr = require( './../../../base/fliplr' );
5757
import flipud = require( './../../../base/flipud' );
5858
import forEach = require( './../../../base/for-each' );
5959
import scalar2ndarray = require( './../../../base/from-scalar' );
60+
import scalar2ndarrayLike = require( './../../../base/from-scalar-like' );
6061
import ind = require( './../../../base/ind' );
6162
import ind2sub = require( './../../../base/ind2sub' );
6263
import iterationOrder = require( './../../../base/iteration-order' );
@@ -1143,6 +1144,33 @@ interface Namespace {
11431144
*/
11441145
scalar2ndarray: typeof scalar2ndarray;
11451146

1147+
/**
1148+
* Returns a zero-dimensional ndarray containing a provided scalar value and having the same data type as a provided input ndarray.
1149+
*
1150+
* @param x - input array
1151+
* @param value - scalar value
1152+
* @returns zero-dimensional ndarray
1153+
*
1154+
* @example
1155+
* var zeros = require( './../../../base/zeros' );
1156+
*
1157+
* var x = zeros( 'float64', [ 2, 2 ], 'row-major' );
1158+
* // returns <ndarray>
1159+
*
1160+
* var y = ns.scalar2ndarrayLike( x, 1.0 );
1161+
* // returns <ndarray>
1162+
*
1163+
* var sh = y.shape;
1164+
* // returns []
1165+
*
1166+
* var dt = y.dtype;
1167+
* // returns 'generic'
1168+
*
1169+
* var v = y.get();
1170+
* // returns 1.0
1171+
*/
1172+
scalar2ndarrayLike: typeof scalar2ndarrayLike;
1173+
11461174
/**
11471175
* Returns an index given an index mode.
11481176
*

0 commit comments

Comments
 (0)