Skip to content

Commit a18cca1

Browse files
committed
Auto-generated commit
1 parent cf5f6a3 commit a18cca1

File tree

6 files changed

+41
-43
lines changed

6 files changed

+41
-43
lines changed

CHANGELOG.md

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
55
<section class="release" id="unreleased">
66

7-
## Unreleased (2024-07-10)
7+
## Unreleased (2024-07-13)
88

99
<section class="packages">
1010

@@ -77,6 +77,28 @@
7777

7878
<!-- /.package -->
7979

80+
<section class="package" id="ndarray-base-buffer-ctors-unreleased">
81+
82+
#### [@stdlib/ndarray/base/buffer-ctors](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/ndarray/base/buffer-ctors)
83+
84+
<details>
85+
86+
<section class="features">
87+
88+
##### Features
89+
90+
- [`0f0dbca`](https://github.com/stdlib-js/stdlib/commit/0f0dbcaa7eddb30c09c8cc394224cd4a409b90a6) - add boolean dtype support to `ndarray/base/buffer-ctors` [(#2571)](https://github.com/stdlib-js/stdlib/pull/2571)
91+
92+
</section>
93+
94+
<!-- /.features -->
95+
96+
</details>
97+
98+
</section>
99+
100+
<!-- /.package -->
101+
80102
<section class="package" id="ndarray-base-nullary-unreleased">
81103

82104
#### [@stdlib/ndarray/base/nullary](https://github.com/stdlib-js/stdlib/tree/develop/lib/node_modules/%40stdlib/ndarray/base/nullary)
@@ -374,6 +396,7 @@ A total of 3 people contributed to this release. Thank you to the following cont
374396

375397
<details>
376398

399+
- [`0f0dbca`](https://github.com/stdlib-js/stdlib/commit/0f0dbcaa7eddb30c09c8cc394224cd4a409b90a6) - **feat:** add boolean dtype support to `ndarray/base/buffer-ctors` [(#2571)](https://github.com/stdlib-js/stdlib/pull/2571) _(by Jaysukh Makvana, Athan Reines)_
377400
- [`1cb0243`](https://github.com/stdlib-js/stdlib/commit/1cb0243d79c25ae193c058bb15ceeebad6cf3cfd) - **feat:** add boolean dtype support to `ndarray/next-dtype` [(#2553)](https://github.com/stdlib-js/stdlib/pull/2553) _(by Jaysukh Makvana)_
378401
- [`131d649`](https://github.com/stdlib-js/stdlib/commit/131d649c6b22a6247121db1fd380658bf4e83b65) - **feat:** add boolean dtype support to `ndarray/mostly-safe-casts` [(#2554)](https://github.com/stdlib-js/stdlib/pull/2554) _(by Jaysukh Makvana, Athan Reines)_
379402
- [`4e860d8`](https://github.com/stdlib-js/stdlib/commit/4e860d827216f445b5abc569a0d7d7d7e61d83f6) - **feat:** add boolean dtype support to `ndarray/same-kind-casts` [(#2555)](https://github.com/stdlib-js/stdlib/pull/2555) _(by Jaysukh Makvana)_

base/buffer-ctors/README.md

Lines changed: 6 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
33
@license Apache-2.0
44
5-
Copyright (c) 2018 The Stdlib Authors.
5+
Copyright (c) 2024 The Stdlib Authors.
66
77
Licensed under the Apache License, Version 2.0 (the "License");
88
you may not use this file except in compliance with the License.
@@ -42,30 +42,14 @@ var ctors = require( '@stdlib/ndarray/base/buffer-ctors' );
4242

4343
#### ctors( dtype )
4444

45-
Returns an ndarray data buffer constructor for a specified data type.
45+
Returns an ndarray data buffer constructor for a specified [data type][@stdlib/ndarray/dtypes].
4646

4747
```javascript
4848
var ctor = ctors( 'float64' );
4949
// returns <Function>
5050
```
5151

52-
The function returns constructors for the following data types:
53-
54-
- `binary`: binary.
55-
- `complex64`: single-precision complex floating-point numbers.
56-
- `complex128`: double-precision complex floating-point numbers.
57-
- `float32`: single-precision floating-point numbers.
58-
- `float64`: double-precision floating-point numbers.
59-
- `generic`: values of any type.
60-
- `int16`: signed 16-bit integers.
61-
- `int32`: signed 32-bit integers.
62-
- `int8`: signed 8-bit integers.
63-
- `uint16`: unsigned 16-bit integers.
64-
- `uint32`: unsigned 32-bit integers.
65-
- `uint8`: unsigned 8-bit integers.
66-
- `uint8c`: unsigned clamped 8-bit integers.
67-
68-
If provided an unknown or unsupported data type, the function returns `null`.
52+
If provided an unknown or unsupported [data type][@stdlib/ndarray/dtypes], the function returns `null`.
6953

7054
```javascript
7155
var ctor = ctors( 'float' );
@@ -97,9 +81,9 @@ var dtypes = require( '@stdlib/ndarray/dtypes' );
9781
var ctors = require( '@stdlib/ndarray/base/buffer-ctors' );
9882

9983
var DTYPES = dtypes();
84+
10085
var ctor;
10186
var i;
102-
10387
for ( i = 0; i < DTYPES.length; i++ ) {
10488
ctor = ctors( DTYPES[ i ] );
10589
console.log( ctor );
@@ -130,6 +114,8 @@ for ( i = 0; i < DTYPES.length; i++ ) {
130114

131115
<section class="links">
132116

117+
[@stdlib/ndarray/dtypes]: https://github.com/stdlib-js/ndarray/tree/main/dtypes
118+
133119
</section>
134120

135121
<!-- /.links -->

base/buffer-ctors/docs/repl.txt

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,22 +2,6 @@
22
{{alias}}( dtype )
33
Returns an ndarray data buffer constructor.
44

5-
The function returns constructors for the following data types:
6-
7-
- binary: binary.
8-
- complex64: single-precision complex floating-point numbers.
9-
- complex128: double-precision complex floating-point numbers.
10-
- float32: single-precision floating-point numbers.
11-
- float64: double-precision floating-point numbers.
12-
- generic: values of any type.
13-
- int16: signed 16-bit integers.
14-
- int32: signed 32-bit integers.
15-
- int8: signed 8-bit integers.
16-
- uint16: unsigned 16-bit integers.
17-
- uint32: unsigned 32-bit integers.
18-
- uint8: unsigned 8-bit integers.
19-
- uint8c: unsigned clamped 8-bit integers.
20-
215
Parameters
226
----------
237
dtype: string

base/buffer-ctors/examples/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ var dtypes = require( './../../../dtypes' );
2222
var ctors = require( './../lib' );
2323

2424
var DTYPES = dtypes();
25+
2526
var ctor;
2627
var i;
27-
2828
for ( i = 0; i < DTYPES.length; i++ ) {
2929
ctor = ctors( DTYPES[ i ] );
3030
console.log( ctor );

base/buffer-ctors/lib/ctors.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* @license Apache-2.0
33
*
4-
* Copyright (c) 2018 The Stdlib Authors.
4+
* Copyright (c) 2024 The Stdlib Authors.
55
*
66
* Licensed under the Apache License, Version 2.0 (the "License");
77
* you may not use this file except in compliance with the License.
@@ -32,6 +32,7 @@ var Uint8Array = require( '@stdlib/array/uint8' );
3232
var Uint8ClampedArray = require( '@stdlib/array/uint8c' );
3333
var Complex64Array = require( '@stdlib/array/complex64' );
3434
var Complex128Array = require( '@stdlib/array/complex128' );
35+
var BooleanArray = require( '@stdlib/array/bool' );
3536

3637

3738
// MAIN //
@@ -50,7 +51,8 @@ var ctors = {
5051
'uint8': Uint8Array,
5152
'uint8c': Uint8ClampedArray,
5253
'complex64': Complex64Array,
53-
'complex128': Complex128Array
54+
'complex128': Complex128Array,
55+
'bool': BooleanArray
5456
};
5557

5658

base/buffer-ctors/test/test.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/**
22
* @license Apache-2.0
33
*
4-
* Copyright (c) 2018 The Stdlib Authors.
4+
* Copyright (c) 2024 The Stdlib Authors.
55
*
66
* Licensed under the Apache License, Version 2.0 (the "License");
77
* you may not use this file except in compliance with the License.
@@ -34,6 +34,7 @@ var Uint8Array = require( '@stdlib/array/uint8' );
3434
var Uint8ClampedArray = require( '@stdlib/array/uint8c' );
3535
var Complex64Array = require( '@stdlib/array/complex64' );
3636
var Complex128Array = require( '@stdlib/array/complex128' );
37+
var BooleanArray = require( '@stdlib/array/bool' );
3738
var isFunction = require( '@stdlib/assert/is-function' );
3839
var ctors = require( './../lib' );
3940

@@ -65,7 +66,8 @@ tape( 'the function returns ndarray data buffer constructors', function test( t
6566
'uint8',
6667
'uint8c',
6768
'complex64',
68-
'complex128'
69+
'complex128',
70+
'bool'
6971
];
7072
expected = [
7173
Buffer,
@@ -80,7 +82,8 @@ tape( 'the function returns ndarray data buffer constructors', function test( t
8082
Uint8Array,
8183
Uint8ClampedArray,
8284
Complex64Array,
83-
Complex128Array
85+
Complex128Array,
86+
BooleanArray
8487
];
8588
for ( i = 0; i < dtypes.length; i++ ) {
8689
ctor = ctors( dtypes[ i ] );

0 commit comments

Comments
 (0)