@stdlib/ndarray-same-kind-casts 0.2.1 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/NOTICE CHANGED
@@ -1 +1 @@
1
- Copyright (c) 2016-2024 The Stdlib Authors.
1
+ Copyright (c) 2016-2026 The Stdlib Authors.
package/README.md CHANGED
@@ -184,7 +184,7 @@ See [LICENSE][stdlib-license].
184
184
 
185
185
  ## Copyright
186
186
 
187
- Copyright © 2016-2024. The Stdlib [Authors][stdlib-authors].
187
+ Copyright © 2016-2026. The Stdlib [Authors][stdlib-authors].
188
188
 
189
189
  </section>
190
190
 
@@ -197,8 +197,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
197
197
  [npm-image]: http://img.shields.io/npm/v/@stdlib/ndarray-same-kind-casts.svg
198
198
  [npm-url]: https://npmjs.org/package/@stdlib/ndarray-same-kind-casts
199
199
 
200
- [test-image]: https://github.com/stdlib-js/ndarray-same-kind-casts/actions/workflows/test.yml/badge.svg?branch=v0.2.1
201
- [test-url]: https://github.com/stdlib-js/ndarray-same-kind-casts/actions/workflows/test.yml?query=branch:v0.2.1
200
+ [test-image]: https://github.com/stdlib-js/ndarray-same-kind-casts/actions/workflows/test.yml/badge.svg?branch=v0.4.0
201
+ [test-url]: https://github.com/stdlib-js/ndarray-same-kind-casts/actions/workflows/test.yml?query=branch:v0.4.0
202
202
 
203
203
  [coverage-image]: https://img.shields.io/codecov/c/github/stdlib-js/ndarray-same-kind-casts/main.svg
204
204
  [coverage-url]: https://codecov.io/github/stdlib-js/ndarray-same-kind-casts?branch=main
@@ -210,8 +210,8 @@ Copyright &copy; 2016-2024. The Stdlib [Authors][stdlib-authors].
210
210
 
211
211
  -->
212
212
 
213
- [chat-image]: https://img.shields.io/gitter/room/stdlib-js/stdlib.svg
214
- [chat-url]: https://app.gitter.im/#/room/#stdlib-js_stdlib:gitter.im
213
+ [chat-image]: https://img.shields.io/badge/zulip-join_chat-brightgreen.svg
214
+ [chat-url]: https://stdlib.zulipchat.com
215
215
 
216
216
  [stdlib]: https://github.com/stdlib-js/stdlib
217
217
 
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- "use strict";var p=function(t,n){return function(){return n||t((n={exports:{}}).exports,n),n.exports}};var m=p(function(A,s){s.exports={float64:{float64:1,float32:1,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:0,binary:0,generic:1},float32:{float64:1,float32:1,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,binary:0,generic:1},int32:{float64:1,float32:0,int32:1,int16:1,int8:1,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:0,binary:0,generic:1},int16:{float64:1,float32:1,int32:1,int16:1,int8:1,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,binary:0,generic:1},int8:{float64:1,float32:1,int32:1,int16:1,int8:1,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,binary:0,generic:1},uint32:{float64:1,float32:0,int32:0,int16:0,int8:0,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:0,binary:0,generic:1},uint16:{float64:1,float32:1,int32:1,int16:0,int8:0,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,binary:0,generic:1},uint8:{float64:1,float32:1,int32:1,int16:1,int8:0,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,binary:0,generic:1},uint8c:{float64:1,float32:1,int32:1,int16:1,int8:0,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,binary:0,generic:1},complex128:{float64:0,float32:0,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,binary:0,generic:0},complex64:{float64:0,float32:0,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,binary:0,generic:0},generic:{float64:0,float32:0,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,binary:0,generic:1},binary:{float64:0,float32:0,int32:0,int16:0,int8:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,binary:1,generic:0}}});var g=p(function(K,v){
2
- var x=require('@stdlib/utils-keys/dist'),b=require('@stdlib/assert-has-own-property/dist'),y=require('@stdlib/ndarray-base-dtype-resolve-str/dist'),f=m(),c;function d(){var t,n,r,u,a,o,l,i,e;for(r={},t=x(f),n=t.length,e=0;e<n;e++){for(a=t[e],l=f[a],u={},i=0;i<n;i++)o=t[i],u[o]=l[o];r[a]=u}return r}function h(){var t,n,r,u,a,o,l,i,e;for(r={},t=x(f),n=t.length,e=0;e<n;e++){for(a=t[e],l=f[a],u=[],i=0;i<n;i++)o=t[i],l[o]===1&&u.push(o);r[a]=u}return r}function q(t){return arguments.length===0?d():(c===void 0&&(c=h()),t=y(t),b(c,t)?c[t].slice():null)}v.exports=q
3
- });var T=g();module.exports=T;
1
+ "use strict";var p=function(t,n){return function(){return n||t((n={exports:{}}).exports,n),n.exports}};var m=p(function(A,g){g.exports={float64:{float64:1,float32:1,float16:1,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:0,complex32:0,binary:0,generic:1,bool:0},float32:{float64:1,float32:1,float16:1,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:0,binary:0,generic:1,bool:0},float16:{float64:1,float32:1,float16:1,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:1,binary:0,generic:1,bool:0},int64:{float64:0,float32:0,float16:0,int64:1,int32:1,int16:1,int8:1,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,complex32:0,binary:0,generic:1,bool:0},int32:{float64:1,float32:0,float16:0,int64:1,int32:1,int16:1,int8:1,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:0,complex32:0,binary:0,generic:1,bool:0},int16:{float64:1,float32:1,float16:0,int64:1,int32:1,int16:1,int8:1,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:0,binary:0,generic:1,bool:0},int8:{float64:1,float32:1,float16:1,int64:1,int32:1,int16:1,int8:1,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:0,binary:0,generic:1,bool:0},uint64:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:1,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:0,complex32:0,binary:0,generic:1,bool:0},uint32:{float64:1,float32:0,float16:0,int64:1,int32:0,int16:0,int8:0,uint64:1,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:0,complex32:0,binary:0,generic:1,bool:0},uint16:{float64:1,float32:1,float16:0,int64:1,int32:1,int16:0,int8:0,uint64:1,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,complex32:0,binary:0,generic:1,bool:0},uint8:{float64:1,float32:1,float16:1,int64:1,int32:1,int16:1,int8:0,uint64:1,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,complex32:1,binary:0,generic:1,bool:0},uint8c:{float64:1,float32:1,float16:1,int64:1,int32:1,int16:1,int8:0,uint64:1,uint32:1,uint16:1,uint8:1,uint8c:1,complex128:1,complex64:1,complex32:1,binary:0,generic:1,bool:0},complex128:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:1,binary:0,generic:0,bool:0},complex64:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:1,binary:0,generic:0,bool:0},complex32:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:1,complex64:1,complex32:1,binary:0,generic:0,bool:0},generic:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,complex32:0,binary:0,generic:1,bool:0},binary:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,complex32:0,binary:1,generic:0,bool:0},bool:{float64:0,float32:0,float16:0,int64:0,int32:0,int16:0,int8:0,uint64:0,uint32:0,uint16:0,uint8:0,uint8c:0,complex128:0,complex64:0,complex32:0,binary:0,generic:1,bool:1}}});var v=p(function(K,b){
2
+ var x=require('@stdlib/utils-keys/dist'),y=require('@stdlib/assert-has-own-property/dist'),s=require('@stdlib/ndarray-base-dtype-resolve-str/dist'),f=m(),r;function d(){var t,n,l,e,u,a,c,i,o;for(l={},t=x(f),n=t.length,o=0;o<n;o++){for(u=t[o],c=f[u],e={},i=0;i<n;i++)a=t[i],e[a]=c[a];l[u]=e}return l}function h(){var t,n,l,e,u,a,c,i,o;for(l={},t=x(f),n=t.length,o=0;o<n;o++){for(u=t[o],c=f[u],e=[],i=0;i<n;i++)a=t[i],c[a]===1&&e.push(a);l[u]=e}return l}function q(t){return arguments.length===0?d():(r===void 0&&(r=h()),t=s(t),y(r,t)?r[t].slice():null)}b.exports=q
3
+ });var T=v();module.exports=T;
4
4
  /** @license Apache-2.0 */
5
5
  //# sourceMappingURL=index.js.map
package/dist/index.js.map CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../lib/same_kind_casts.json", "../lib/main.js", "../lib/index.js"],
4
- "sourcesContent": ["{\n\t\"float64\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 0,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"float32\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"int32\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 0,\n\t\t\"int32\": 1,\n\t\t\"int16\": 1,\n\t\t\"int8\": 1,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 0,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"int16\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 1,\n\t\t\"int16\": 1,\n\t\t\"int8\": 1,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"int8\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 1,\n\t\t\"int16\": 1,\n\t\t\"int8\": 1,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"uint32\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 0,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 1,\n\t\t\"uint16\": 1,\n\t\t\"uint8\": 1,\n\t\t\"uint8c\": 1,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 0,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"uint16\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 1,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 1,\n\t\t\"uint16\": 1,\n\t\t\"uint8\": 1,\n\t\t\"uint8c\": 1,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"uint8\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 1,\n\t\t\"int16\": 1,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 1,\n\t\t\"uint16\": 1,\n\t\t\"uint8\": 1,\n\t\t\"uint8c\": 1,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"uint8c\": {\n\t\t\"float64\": 1,\n\t\t\"float32\": 1,\n\t\t\"int32\": 1,\n\t\t\"int16\": 1,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 1,\n\t\t\"uint16\": 1,\n\t\t\"uint8\": 1,\n\t\t\"uint8c\": 1,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"complex128\": {\n\t\t\"float64\": 0,\n\t\t\"float32\": 0,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 0\n\t},\n\t\"complex64\": {\n\t\t\"float64\": 0,\n\t\t\"float32\": 0,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 1,\n\t\t\"complex64\": 1,\n\t\t\"binary\": 0,\n\t\t\"generic\": 0\n\t},\n\t\"generic\": {\n\t\t\"float64\": 0,\n\t\t\"float32\": 0,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 0,\n\t\t\"complex64\": 0,\n\t\t\"binary\": 0,\n\t\t\"generic\": 1\n\t},\n\t\"binary\": {\n\t\t\"float64\": 0,\n\t\t\"float32\": 0,\n\t\t\"int32\": 0,\n\t\t\"int16\": 0,\n\t\t\"int8\": 0,\n\t\t\"uint32\": 0,\n\t\t\"uint16\": 0,\n\t\t\"uint8\": 0,\n\t\t\"uint8c\": 0,\n\t\t\"complex128\": 0,\n\t\t\"complex64\": 0,\n\t\t\"binary\": 1,\n\t\t\"generic\": 0\n\t}\n}\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar objectKeys = require( '@stdlib/utils-keys' );\nvar hasOwnProp = require( '@stdlib/assert-has-own-property' );\nvar resolve = require( '@stdlib/ndarray-base-dtype-resolve-str' );\nvar SAME_KIND_CASTS = require( './same_kind_casts.json' );\n\n\n// VARIABLES //\n\nvar TABLE;\n\n\n// FUNCTIONS //\n\n/**\n* Generates a full table of same \"kind\" casts for each ndarray data type.\n*\n* @private\n* @returns {Object} table\n*/\nfunction generateFullTable() {\n\tvar dtypes;\n\tvar ntypes;\n\tvar out;\n\tvar tmp;\n\tvar dt1;\n\tvar dt2;\n\tvar o;\n\tvar j;\n\tvar i;\n\n\tout = {};\n\tdtypes = objectKeys( SAME_KIND_CASTS );\n\tntypes = dtypes.length;\n\tfor ( i = 0; i < ntypes; i++ ) {\n\t\tdt1 = dtypes[ i ];\n\t\to = SAME_KIND_CASTS[ dt1 ];\n\t\ttmp = {};\n\t\tfor ( j = 0; j < ntypes; j++ ) {\n\t\t\tdt2 = dtypes[ j ];\n\t\t\ttmp[ dt2 ] = o[ dt2 ];\n\t\t}\n\t\tout[ dt1 ] = tmp;\n\t}\n\treturn out;\n}\n\n/**\n* Generates a table of same \"kind\" casts for each ndarray data type.\n*\n* @private\n* @returns {Object} table\n*/\nfunction generateTable() {\n\tvar dtypes;\n\tvar ntypes;\n\tvar out;\n\tvar tmp;\n\tvar dt1;\n\tvar dt2;\n\tvar o;\n\tvar j;\n\tvar i;\n\n\tout = {};\n\tdtypes = objectKeys( SAME_KIND_CASTS );\n\tntypes = dtypes.length;\n\tfor ( i = 0; i < ntypes; i++ ) {\n\t\tdt1 = dtypes[ i ];\n\t\to = SAME_KIND_CASTS[ dt1 ];\n\t\ttmp = [];\n\t\tfor ( j = 0; j < ntypes; j++ ) {\n\t\t\tdt2 = dtypes[ j ];\n\t\t\tif ( o[ dt2 ] === 1 ) {\n\t\t\t\ttmp.push( dt2 );\n\t\t\t}\n\t\t}\n\t\tout[ dt1 ] = tmp;\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Returns a list of ndarray data types to which a provided ndarray data type can be safely cast or cast within the same \"kind\".\n*\n* @param {*} [dtype] - ndarray data type value\n* @returns {(Object|StringArray|null)} list of ndarray data types or null\n*\n* @example\n* var list = sameKindCasts( 'float32' );\n* // returns [...]\n*/\nfunction sameKindCasts( dtype ) {\n\tif ( arguments.length === 0 ) {\n\t\treturn generateFullTable();\n\t}\n\tif ( TABLE === void 0 ) {\n\t\t// Lazily generate table...\n\t\tTABLE = generateTable();\n\t}\n\tdtype = resolve( dtype );\n\tif ( hasOwnProp( TABLE, dtype ) ) {\n\t\treturn TABLE[ dtype ].slice();\n\t}\n\treturn null;\n}\n\n\n// EXPORTS //\n\nmodule.exports = sameKindCasts;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Return a list of ndarray data types to which a provided ndarray data type can be safely cast or cast within the same \"kind\".\n*\n* @module @stdlib/ndarray-same-kind-casts\n*\n* @example\n* var sameKindCasts = require( '@stdlib/ndarray-same-kind-casts' );\n*\n* var list = sameKindCasts( 'float32' );\n* // returns [...]\n*/\n\n// MODULES //\n\nvar main = require( './main.js' );\n\n\n// EXPORTS //\n\nmodule.exports = main;\n"],
5
- "mappings": "uGAAA,IAAAA,EAAAC,EAAA,SAAAC,EAAAC,EAAA,CAAAA,EAAA,SACC,QAAW,CACV,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,QAAW,CACV,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,MAAS,CACR,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,MAAS,CACR,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,KAAQ,CACP,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,OAAU,CACT,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,OAAU,CACT,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,MAAS,CACR,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,OAAU,CACT,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,WAAc,CACb,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,UAAa,CACZ,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,QAAW,CACV,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,EACA,OAAU,CACT,QAAW,EACX,QAAW,EACX,MAAS,EACT,MAAS,EACT,KAAQ,EACR,OAAU,EACV,OAAU,EACV,MAAS,EACT,OAAU,EACV,WAAc,EACd,UAAa,EACb,OAAU,EACV,QAAW,CACZ,CACD,ICpMA,IAAAC,EAAAC,EAAA,SAAAC,EAAAC,EAAA,cAsBA,IAAIC,EAAa,QAAS,oBAAqB,EAC3CC,EAAa,QAAS,iCAAkC,EACxDC,EAAU,QAAS,wCAAyC,EAC5DC,EAAkB,IAKlBC,EAWJ,SAASC,GAAoB,CAC5B,IAAIC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EAKJ,IAHAN,EAAM,CAAC,EACPF,EAASN,EAAYG,CAAgB,EACrCI,EAASD,EAAO,OACVQ,EAAI,EAAGA,EAAIP,EAAQO,IAAM,CAI9B,IAHAJ,EAAMJ,EAAQQ,CAAE,EAChBF,EAAIT,EAAiBO,CAAI,EACzBD,EAAM,CAAC,EACDI,EAAI,EAAGA,EAAIN,EAAQM,IACxBF,EAAML,EAAQO,CAAE,EAChBJ,EAAKE,CAAI,EAAIC,EAAGD,CAAI,EAErBH,EAAKE,CAAI,EAAID,CACd,CACA,OAAOD,CACR,CAQA,SAASO,GAAgB,CACxB,IAAIT,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EACAC,EAKJ,IAHAN,EAAM,CAAC,EACPF,EAASN,EAAYG,CAAgB,EACrCI,EAASD,EAAO,OACVQ,EAAI,EAAGA,EAAIP,EAAQO,IAAM,CAI9B,IAHAJ,EAAMJ,EAAQQ,CAAE,EAChBF,EAAIT,EAAiBO,CAAI,EACzBD,EAAM,CAAC,EACDI,EAAI,EAAGA,EAAIN,EAAQM,IACxBF,EAAML,EAAQO,CAAE,EACXD,EAAGD,CAAI,IAAM,GACjBF,EAAI,KAAME,CAAI,EAGhBH,EAAKE,CAAI,EAAID,CACd,CACA,OAAOD,CACR,CAeA,SAASQ,EAAeC,EAAQ,CAC/B,OAAK,UAAU,SAAW,EAClBZ,EAAkB,GAErBD,IAAU,SAEdA,EAAQW,EAAc,GAEvBE,EAAQf,EAASe,CAAM,EAClBhB,EAAYG,EAAOa,CAAM,EACtBb,EAAOa,CAAM,EAAE,MAAM,EAEtB,KACR,CAKAlB,EAAO,QAAUiB,ICpGjB,IAAIE,EAAO,IAKX,OAAO,QAAUA",
4
+ "sourcesContent": ["{\n \"float64\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"float32\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"float16\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"int64\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 1,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 0,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"int32\": {\n \"float64\": 1,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 1,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"int16\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 0,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 1,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"int8\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 1,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"uint64\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 1,\n \"uint32\": 1,\n \"uint16\": 1,\n \"uint8\": 1,\n \"uint8c\": 1,\n \"complex128\": 1,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"uint32\": {\n \"float64\": 1,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 1,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 1,\n \"uint32\": 1,\n \"uint16\": 1,\n \"uint8\": 1,\n \"uint8c\": 1,\n \"complex128\": 1,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"uint16\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 0,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 1,\n \"uint32\": 1,\n \"uint16\": 1,\n \"uint8\": 1,\n \"uint8c\": 1,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"uint8\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 0,\n \"uint64\": 1,\n \"uint32\": 1,\n \"uint16\": 1,\n \"uint8\": 1,\n \"uint8c\": 1,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"uint8c\": {\n \"float64\": 1,\n \"float32\": 1,\n \"float16\": 1,\n \"int64\": 1,\n \"int32\": 1,\n \"int16\": 1,\n \"int8\": 0,\n \"uint64\": 1,\n \"uint32\": 1,\n \"uint16\": 1,\n \"uint8\": 1,\n \"uint8c\": 1,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"complex128\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 0,\n \"bool\": 0\n },\n \"complex64\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 0,\n \"bool\": 0\n },\n \"complex32\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 1,\n \"complex64\": 1,\n \"complex32\": 1,\n \"binary\": 0,\n \"generic\": 0,\n \"bool\": 0\n },\n \"generic\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 0,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 0\n },\n \"binary\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 0,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 1,\n \"generic\": 0,\n \"bool\": 0\n },\n \"bool\": {\n \"float64\": 0,\n \"float32\": 0,\n \"float16\": 0,\n \"int64\": 0,\n \"int32\": 0,\n \"int16\": 0,\n \"int8\": 0,\n \"uint64\": 0,\n \"uint32\": 0,\n \"uint16\": 0,\n \"uint8\": 0,\n \"uint8c\": 0,\n \"complex128\": 0,\n \"complex64\": 0,\n \"complex32\": 0,\n \"binary\": 0,\n \"generic\": 1,\n \"bool\": 1\n }\n}\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n// MODULES //\n\nvar objectKeys = require( '@stdlib/utils-keys' );\nvar hasOwnProp = require( '@stdlib/assert-has-own-property' );\nvar resolve = require( '@stdlib/ndarray-base-dtype-resolve-str' );\nvar SAME_KIND_CASTS = require( './same_kind_casts.json' );\n\n\n// VARIABLES //\n\nvar TABLE;\n\n\n// FUNCTIONS //\n\n/**\n* Generates a full table of same \"kind\" casts for each ndarray data type.\n*\n* @private\n* @returns {Object} table\n*/\nfunction generateFullTable() {\n\tvar dtypes;\n\tvar ntypes;\n\tvar out;\n\tvar tmp;\n\tvar dt1;\n\tvar dt2;\n\tvar o;\n\tvar j;\n\tvar i;\n\n\tout = {};\n\tdtypes = objectKeys( SAME_KIND_CASTS );\n\tntypes = dtypes.length;\n\tfor ( i = 0; i < ntypes; i++ ) {\n\t\tdt1 = dtypes[ i ];\n\t\to = SAME_KIND_CASTS[ dt1 ];\n\t\ttmp = {};\n\t\tfor ( j = 0; j < ntypes; j++ ) {\n\t\t\tdt2 = dtypes[ j ];\n\t\t\ttmp[ dt2 ] = o[ dt2 ];\n\t\t}\n\t\tout[ dt1 ] = tmp;\n\t}\n\treturn out;\n}\n\n/**\n* Generates a table of same \"kind\" casts for each ndarray data type.\n*\n* @private\n* @returns {Object} table\n*/\nfunction generateTable() {\n\tvar dtypes;\n\tvar ntypes;\n\tvar out;\n\tvar tmp;\n\tvar dt1;\n\tvar dt2;\n\tvar o;\n\tvar j;\n\tvar i;\n\n\tout = {};\n\tdtypes = objectKeys( SAME_KIND_CASTS );\n\tntypes = dtypes.length;\n\tfor ( i = 0; i < ntypes; i++ ) {\n\t\tdt1 = dtypes[ i ];\n\t\to = SAME_KIND_CASTS[ dt1 ];\n\t\ttmp = [];\n\t\tfor ( j = 0; j < ntypes; j++ ) {\n\t\t\tdt2 = dtypes[ j ];\n\t\t\tif ( o[ dt2 ] === 1 ) {\n\t\t\t\ttmp.push( dt2 );\n\t\t\t}\n\t\t}\n\t\tout[ dt1 ] = tmp;\n\t}\n\treturn out;\n}\n\n\n// MAIN //\n\n/**\n* Returns a list of ndarray data types to which a provided ndarray data type can be safely cast or cast within the same \"kind\".\n*\n* @param {*} [dtype] - ndarray data type value\n* @returns {(Object|StringArray|null)} list of ndarray data types or null\n*\n* @example\n* var list = sameKindCasts( 'float32' );\n* // returns [...]\n*/\nfunction sameKindCasts( dtype ) {\n\tif ( arguments.length === 0 ) {\n\t\treturn generateFullTable();\n\t}\n\tif ( TABLE === void 0 ) {\n\t\t// Lazily generate table...\n\t\tTABLE = generateTable();\n\t}\n\tdtype = resolve( dtype );\n\tif ( hasOwnProp( TABLE, dtype ) ) {\n\t\treturn TABLE[ dtype ].slice();\n\t}\n\treturn null;\n}\n\n\n// EXPORTS //\n\nmodule.exports = sameKindCasts;\n", "/**\n* @license Apache-2.0\n*\n* Copyright (c) 2018 The Stdlib Authors.\n*\n* Licensed under the Apache License, Version 2.0 (the \"License\");\n* you may not use this file except in compliance with the License.\n* You may obtain a copy of the License at\n*\n* http://www.apache.org/licenses/LICENSE-2.0\n*\n* Unless required by applicable law or agreed to in writing, software\n* distributed under the License is distributed on an \"AS IS\" BASIS,\n* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n* See the License for the specific language governing permissions and\n* limitations under the License.\n*/\n\n'use strict';\n\n/**\n* Return a list of ndarray data types to which a provided ndarray data type can be safely cast or cast within the same \"kind\".\n*\n* @module @stdlib/ndarray-same-kind-casts\n*\n* @example\n* var sameKindCasts = require( '@stdlib/ndarray-same-kind-casts' );\n*\n* var list = sameKindCasts( 'float32' );\n* // returns [...]\n*/\n\n// MODULES //\n\nvar main = require( './main.js' );\n\n\n// EXPORTS //\n\nmodule.exports = main;\n"],
5
+ "mappings": "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",
6
6
  "names": ["require_same_kind_casts", "__commonJSMin", "exports", "module", "require_main", "__commonJSMin", "exports", "module", "objectKeys", "hasOwnProp", "resolve", "SAME_KIND_CASTS", "TABLE", "generateFullTable", "dtypes", "ntypes", "out", "tmp", "dt1", "dt2", "o", "j", "i", "generateTable", "sameKindCasts", "dtype", "main"]
7
7
  }
@@ -41,9 +41,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT64[ STDLIB_NDARRAY_NDTYPES ] =
41
41
  [ STDLIB_NDARRAY_INT64 ] = 0,
42
42
  [ STDLIB_NDARRAY_UINT64 ] = 0,
43
43
 
44
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
44
45
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
45
46
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
46
47
 
48
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
47
49
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
48
50
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
49
51
 
@@ -65,9 +67,37 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT32[ STDLIB_NDARRAY_NDTYPES ] =
65
67
  [ STDLIB_NDARRAY_INT64 ] = 0,
66
68
  [ STDLIB_NDARRAY_UINT64 ] = 0,
67
69
 
70
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
68
71
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
69
72
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
70
73
 
74
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
75
+ [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
76
+ [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
77
+
78
+ [ STDLIB_NDARRAY_BOOL ] = 0,
79
+
80
+ [ STDLIB_NDARRAY_BINARY ] = 0,
81
+ [ STDLIB_NDARRAY_GENERIC ] = 0
82
+ };
83
+
84
+ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT16[ STDLIB_NDARRAY_NDTYPES ] = {
85
+
86
+ [ STDLIB_NDARRAY_INT8 ] = 0,
87
+ [ STDLIB_NDARRAY_UINT8 ] = 0,
88
+ [ STDLIB_NDARRAY_UINT8C ] = 0,
89
+ [ STDLIB_NDARRAY_INT16 ] = 0,
90
+ [ STDLIB_NDARRAY_UINT16 ] = 0,
91
+ [ STDLIB_NDARRAY_INT32 ] = 0,
92
+ [ STDLIB_NDARRAY_UINT32 ] = 0,
93
+ [ STDLIB_NDARRAY_INT64 ] = 0,
94
+ [ STDLIB_NDARRAY_UINT64 ] = 0,
95
+
96
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
97
+ [ STDLIB_NDARRAY_FLOAT32 ] = 1,
98
+ [ STDLIB_NDARRAY_FLOAT64 ] = 1,
99
+
100
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
71
101
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
72
102
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
73
103
 
@@ -89,9 +119,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_UINT64[ STDLIB_NDARRAY_NDTYPES ] = {
89
119
  [ STDLIB_NDARRAY_INT64 ] = 0,
90
120
  [ STDLIB_NDARRAY_UINT64 ] = 1,
91
121
 
122
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
92
123
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
93
124
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
94
125
 
126
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
95
127
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
96
128
  [ STDLIB_NDARRAY_COMPLEX128 ] = 0,
97
129
 
@@ -113,9 +145,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_INT64[ STDLIB_NDARRAY_NDTYPES ] = {
113
145
  [ STDLIB_NDARRAY_INT64 ] = 1,
114
146
  [ STDLIB_NDARRAY_UINT64 ] = 0,
115
147
 
148
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
116
149
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
117
150
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
118
151
 
152
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
119
153
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
120
154
  [ STDLIB_NDARRAY_COMPLEX128 ] = 0,
121
155
 
@@ -137,9 +171,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_UINT32[ STDLIB_NDARRAY_NDTYPES ] = {
137
171
  [ STDLIB_NDARRAY_INT64 ] = 1,
138
172
  [ STDLIB_NDARRAY_UINT64 ] = 1,
139
173
 
174
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
140
175
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
141
176
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
142
177
 
178
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
143
179
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
144
180
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
145
181
 
@@ -161,9 +197,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_INT32[ STDLIB_NDARRAY_NDTYPES ] = {
161
197
  [ STDLIB_NDARRAY_INT64 ] = 1,
162
198
  [ STDLIB_NDARRAY_UINT64 ] = 0,
163
199
 
200
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
164
201
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
165
202
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
166
203
 
204
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
167
205
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
168
206
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
169
207
 
@@ -185,9 +223,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_UINT16[ STDLIB_NDARRAY_NDTYPES ] = {
185
223
  [ STDLIB_NDARRAY_INT64 ] = 1,
186
224
  [ STDLIB_NDARRAY_UINT64 ] = 1,
187
225
 
226
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
188
227
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
189
228
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
190
229
 
230
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
191
231
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
192
232
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
193
233
 
@@ -209,9 +249,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_INT16[ STDLIB_NDARRAY_NDTYPES ] = {
209
249
  [ STDLIB_NDARRAY_INT64 ] = 1,
210
250
  [ STDLIB_NDARRAY_UINT64 ] = 0,
211
251
 
252
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
212
253
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
213
254
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
214
255
 
256
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
215
257
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
216
258
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
217
259
 
@@ -233,9 +275,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_UINT8[ STDLIB_NDARRAY_NDTYPES ] = {
233
275
  [ STDLIB_NDARRAY_INT64 ] = 1,
234
276
  [ STDLIB_NDARRAY_UINT64 ] = 1,
235
277
 
278
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
236
279
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
237
280
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
238
281
 
282
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
239
283
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
240
284
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
241
285
 
@@ -257,9 +301,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_UINT8C[ STDLIB_NDARRAY_NDTYPES ] = {
257
301
  [ STDLIB_NDARRAY_INT64 ] = 1,
258
302
  [ STDLIB_NDARRAY_UINT64 ] = 1,
259
303
 
304
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
260
305
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
261
306
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
262
307
 
308
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
263
309
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
264
310
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
265
311
 
@@ -281,9 +327,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_INT8[ STDLIB_NDARRAY_NDTYPES ] = {
281
327
  [ STDLIB_NDARRAY_INT64 ] = 1,
282
328
  [ STDLIB_NDARRAY_UINT64 ] = 0,
283
329
 
330
+ [ STDLIB_NDARRAY_FLOAT16 ] = 1,
284
331
  [ STDLIB_NDARRAY_FLOAT32 ] = 1,
285
332
  [ STDLIB_NDARRAY_FLOAT64 ] = 1,
286
333
 
334
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
287
335
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
288
336
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
289
337
 
@@ -305,9 +353,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_BOOL[ STDLIB_NDARRAY_NDTYPES ] = {
305
353
  [ STDLIB_NDARRAY_INT64 ] = 0,
306
354
  [ STDLIB_NDARRAY_UINT64 ] = 0,
307
355
 
356
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
308
357
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
309
358
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
310
359
 
360
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
311
361
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
312
362
  [ STDLIB_NDARRAY_COMPLEX128 ] = 0,
313
363
 
@@ -329,9 +379,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX128[ STDLIB_NDARRAY_NDTYPES ]
329
379
  [ STDLIB_NDARRAY_INT64 ] = 0,
330
380
  [ STDLIB_NDARRAY_UINT64 ] = 0,
331
381
 
382
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
332
383
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
333
384
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
334
385
 
386
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
335
387
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
336
388
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
337
389
 
@@ -353,9 +405,37 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX64[ STDLIB_NDARRAY_NDTYPES ]
353
405
  [ STDLIB_NDARRAY_INT64 ] = 0,
354
406
  [ STDLIB_NDARRAY_UINT64 ] = 0,
355
407
 
408
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
409
+ [ STDLIB_NDARRAY_FLOAT32 ] = 0,
410
+ [ STDLIB_NDARRAY_FLOAT64 ] = 0,
411
+
412
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
413
+ [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
414
+ [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
415
+
416
+ [ STDLIB_NDARRAY_BOOL ] = 0,
417
+
418
+ [ STDLIB_NDARRAY_BINARY ] = 0,
419
+ [ STDLIB_NDARRAY_GENERIC ] = 0
420
+ };
421
+
422
+ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX32[ STDLIB_NDARRAY_NDTYPES ] = {
423
+
424
+ [ STDLIB_NDARRAY_INT8 ] = 0,
425
+ [ STDLIB_NDARRAY_UINT8 ] = 0,
426
+ [ STDLIB_NDARRAY_UINT8C ] = 0,
427
+ [ STDLIB_NDARRAY_INT16 ] = 0,
428
+ [ STDLIB_NDARRAY_UINT16 ] = 0,
429
+ [ STDLIB_NDARRAY_INT32 ] = 0,
430
+ [ STDLIB_NDARRAY_UINT32 ] = 0,
431
+ [ STDLIB_NDARRAY_INT64 ] = 0,
432
+ [ STDLIB_NDARRAY_UINT64 ] = 0,
433
+
434
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
356
435
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
357
436
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
358
437
 
438
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 1,
359
439
  [ STDLIB_NDARRAY_COMPLEX64 ] = 1,
360
440
  [ STDLIB_NDARRAY_COMPLEX128 ] = 1,
361
441
 
@@ -377,9 +457,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_BINARY[ STDLIB_NDARRAY_NDTYPES ] = {
377
457
  [ STDLIB_NDARRAY_INT64 ] = 0,
378
458
  [ STDLIB_NDARRAY_UINT64 ] = 0,
379
459
 
460
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
380
461
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
381
462
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
382
463
 
464
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
383
465
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
384
466
  [ STDLIB_NDARRAY_COMPLEX128 ] = 0,
385
467
 
@@ -401,9 +483,11 @@ const int8_t STDLIB_NDARRAY_SAME_KIND_CASTS_GENERIC[ STDLIB_NDARRAY_NDTYPES ] =
401
483
  [ STDLIB_NDARRAY_INT64 ] = 0,
402
484
  [ STDLIB_NDARRAY_UINT64 ] = 0,
403
485
 
486
+ [ STDLIB_NDARRAY_FLOAT16 ] = 0,
404
487
  [ STDLIB_NDARRAY_FLOAT32 ] = 0,
405
488
  [ STDLIB_NDARRAY_FLOAT64 ] = 0,
406
489
 
490
+ [ STDLIB_NDARRAY_COMPLEX32 ] = 0,
407
491
  [ STDLIB_NDARRAY_COMPLEX64 ] = 0,
408
492
  [ STDLIB_NDARRAY_COMPLEX128 ] = 0,
409
493
 
@@ -426,9 +510,11 @@ const int8_t *STDLIB_NDARRAY_SAME_KIND_CASTS[ STDLIB_NDARRAY_NDTYPES ] = {
426
510
  [ STDLIB_NDARRAY_INT64 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_INT64,
427
511
  [ STDLIB_NDARRAY_UINT64 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_UINT64,
428
512
 
513
+ [ STDLIB_NDARRAY_FLOAT16 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT16,
429
514
  [ STDLIB_NDARRAY_FLOAT32 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT32,
430
515
  [ STDLIB_NDARRAY_FLOAT64 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_FLOAT64,
431
516
 
517
+ [ STDLIB_NDARRAY_COMPLEX32 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX32,
432
518
  [ STDLIB_NDARRAY_COMPLEX64 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX64,
433
519
  [ STDLIB_NDARRAY_COMPLEX128 ] = STDLIB_NDARRAY_SAME_KIND_CASTS_COMPLEX128,
434
520
 
@@ -1,197 +1,362 @@
1
1
  {
2
- "float64": {
3
- "float64": 1,
4
- "float32": 1,
5
- "int32": 0,
6
- "int16": 0,
7
- "int8": 0,
8
- "uint32": 0,
9
- "uint16": 0,
10
- "uint8": 0,
11
- "uint8c": 0,
12
- "complex128": 1,
13
- "complex64": 0,
14
- "binary": 0,
15
- "generic": 1
16
- },
17
- "float32": {
18
- "float64": 1,
19
- "float32": 1,
20
- "int32": 0,
21
- "int16": 0,
22
- "int8": 0,
23
- "uint32": 0,
24
- "uint16": 0,
25
- "uint8": 0,
26
- "uint8c": 0,
27
- "complex128": 1,
28
- "complex64": 1,
29
- "binary": 0,
30
- "generic": 1
31
- },
32
- "int32": {
33
- "float64": 1,
34
- "float32": 0,
35
- "int32": 1,
36
- "int16": 1,
37
- "int8": 1,
38
- "uint32": 0,
39
- "uint16": 0,
40
- "uint8": 0,
41
- "uint8c": 0,
42
- "complex128": 1,
43
- "complex64": 0,
44
- "binary": 0,
45
- "generic": 1
46
- },
47
- "int16": {
48
- "float64": 1,
49
- "float32": 1,
50
- "int32": 1,
51
- "int16": 1,
52
- "int8": 1,
53
- "uint32": 0,
54
- "uint16": 0,
55
- "uint8": 0,
56
- "uint8c": 0,
57
- "complex128": 1,
58
- "complex64": 1,
59
- "binary": 0,
60
- "generic": 1
61
- },
62
- "int8": {
63
- "float64": 1,
64
- "float32": 1,
65
- "int32": 1,
66
- "int16": 1,
67
- "int8": 1,
68
- "uint32": 0,
69
- "uint16": 0,
70
- "uint8": 0,
71
- "uint8c": 0,
72
- "complex128": 1,
73
- "complex64": 1,
74
- "binary": 0,
75
- "generic": 1
76
- },
77
- "uint32": {
78
- "float64": 1,
79
- "float32": 0,
80
- "int32": 0,
81
- "int16": 0,
82
- "int8": 0,
83
- "uint32": 1,
84
- "uint16": 1,
85
- "uint8": 1,
86
- "uint8c": 1,
87
- "complex128": 1,
88
- "complex64": 0,
89
- "binary": 0,
90
- "generic": 1
91
- },
92
- "uint16": {
93
- "float64": 1,
94
- "float32": 1,
95
- "int32": 1,
96
- "int16": 0,
97
- "int8": 0,
98
- "uint32": 1,
99
- "uint16": 1,
100
- "uint8": 1,
101
- "uint8c": 1,
102
- "complex128": 1,
103
- "complex64": 1,
104
- "binary": 0,
105
- "generic": 1
106
- },
107
- "uint8": {
108
- "float64": 1,
109
- "float32": 1,
110
- "int32": 1,
111
- "int16": 1,
112
- "int8": 0,
113
- "uint32": 1,
114
- "uint16": 1,
115
- "uint8": 1,
116
- "uint8c": 1,
117
- "complex128": 1,
118
- "complex64": 1,
119
- "binary": 0,
120
- "generic": 1
121
- },
122
- "uint8c": {
123
- "float64": 1,
124
- "float32": 1,
125
- "int32": 1,
126
- "int16": 1,
127
- "int8": 0,
128
- "uint32": 1,
129
- "uint16": 1,
130
- "uint8": 1,
131
- "uint8c": 1,
132
- "complex128": 1,
133
- "complex64": 1,
134
- "binary": 0,
135
- "generic": 1
136
- },
137
- "complex128": {
138
- "float64": 0,
139
- "float32": 0,
140
- "int32": 0,
141
- "int16": 0,
142
- "int8": 0,
143
- "uint32": 0,
144
- "uint16": 0,
145
- "uint8": 0,
146
- "uint8c": 0,
147
- "complex128": 1,
148
- "complex64": 1,
149
- "binary": 0,
150
- "generic": 0
151
- },
152
- "complex64": {
153
- "float64": 0,
154
- "float32": 0,
155
- "int32": 0,
156
- "int16": 0,
157
- "int8": 0,
158
- "uint32": 0,
159
- "uint16": 0,
160
- "uint8": 0,
161
- "uint8c": 0,
162
- "complex128": 1,
163
- "complex64": 1,
164
- "binary": 0,
165
- "generic": 0
166
- },
167
- "generic": {
168
- "float64": 0,
169
- "float32": 0,
170
- "int32": 0,
171
- "int16": 0,
172
- "int8": 0,
173
- "uint32": 0,
174
- "uint16": 0,
175
- "uint8": 0,
176
- "uint8c": 0,
177
- "complex128": 0,
178
- "complex64": 0,
179
- "binary": 0,
180
- "generic": 1
181
- },
182
- "binary": {
183
- "float64": 0,
184
- "float32": 0,
185
- "int32": 0,
186
- "int16": 0,
187
- "int8": 0,
188
- "uint32": 0,
189
- "uint16": 0,
190
- "uint8": 0,
191
- "uint8c": 0,
192
- "complex128": 0,
193
- "complex64": 0,
194
- "binary": 1,
195
- "generic": 0
196
- }
2
+ "float64": {
3
+ "float64": 1,
4
+ "float32": 1,
5
+ "float16": 1,
6
+ "int64": 0,
7
+ "int32": 0,
8
+ "int16": 0,
9
+ "int8": 0,
10
+ "uint64": 0,
11
+ "uint32": 0,
12
+ "uint16": 0,
13
+ "uint8": 0,
14
+ "uint8c": 0,
15
+ "complex128": 1,
16
+ "complex64": 0,
17
+ "complex32": 0,
18
+ "binary": 0,
19
+ "generic": 1,
20
+ "bool": 0
21
+ },
22
+ "float32": {
23
+ "float64": 1,
24
+ "float32": 1,
25
+ "float16": 1,
26
+ "int64": 0,
27
+ "int32": 0,
28
+ "int16": 0,
29
+ "int8": 0,
30
+ "uint64": 0,
31
+ "uint32": 0,
32
+ "uint16": 0,
33
+ "uint8": 0,
34
+ "uint8c": 0,
35
+ "complex128": 1,
36
+ "complex64": 1,
37
+ "complex32": 0,
38
+ "binary": 0,
39
+ "generic": 1,
40
+ "bool": 0
41
+ },
42
+ "float16": {
43
+ "float64": 1,
44
+ "float32": 1,
45
+ "float16": 1,
46
+ "int64": 0,
47
+ "int32": 0,
48
+ "int16": 0,
49
+ "int8": 0,
50
+ "uint64": 0,
51
+ "uint32": 0,
52
+ "uint16": 0,
53
+ "uint8": 0,
54
+ "uint8c": 0,
55
+ "complex128": 1,
56
+ "complex64": 1,
57
+ "complex32": 1,
58
+ "binary": 0,
59
+ "generic": 1,
60
+ "bool": 0
61
+ },
62
+ "int64": {
63
+ "float64": 0,
64
+ "float32": 0,
65
+ "float16": 0,
66
+ "int64": 1,
67
+ "int32": 1,
68
+ "int16": 1,
69
+ "int8": 1,
70
+ "uint64": 0,
71
+ "uint32": 0,
72
+ "uint16": 0,
73
+ "uint8": 0,
74
+ "uint8c": 0,
75
+ "complex128": 0,
76
+ "complex64": 0,
77
+ "complex32": 0,
78
+ "binary": 0,
79
+ "generic": 1,
80
+ "bool": 0
81
+ },
82
+ "int32": {
83
+ "float64": 1,
84
+ "float32": 0,
85
+ "float16": 0,
86
+ "int64": 1,
87
+ "int32": 1,
88
+ "int16": 1,
89
+ "int8": 1,
90
+ "uint64": 0,
91
+ "uint32": 0,
92
+ "uint16": 0,
93
+ "uint8": 0,
94
+ "uint8c": 0,
95
+ "complex128": 1,
96
+ "complex64": 0,
97
+ "complex32": 0,
98
+ "binary": 0,
99
+ "generic": 1,
100
+ "bool": 0
101
+ },
102
+ "int16": {
103
+ "float64": 1,
104
+ "float32": 1,
105
+ "float16": 0,
106
+ "int64": 1,
107
+ "int32": 1,
108
+ "int16": 1,
109
+ "int8": 1,
110
+ "uint64": 0,
111
+ "uint32": 0,
112
+ "uint16": 0,
113
+ "uint8": 0,
114
+ "uint8c": 0,
115
+ "complex128": 1,
116
+ "complex64": 1,
117
+ "complex32": 0,
118
+ "binary": 0,
119
+ "generic": 1,
120
+ "bool": 0
121
+ },
122
+ "int8": {
123
+ "float64": 1,
124
+ "float32": 1,
125
+ "float16": 1,
126
+ "int64": 1,
127
+ "int32": 1,
128
+ "int16": 1,
129
+ "int8": 1,
130
+ "uint64": 0,
131
+ "uint32": 0,
132
+ "uint16": 0,
133
+ "uint8": 0,
134
+ "uint8c": 0,
135
+ "complex128": 1,
136
+ "complex64": 1,
137
+ "complex32": 0,
138
+ "binary": 0,
139
+ "generic": 1,
140
+ "bool": 0
141
+ },
142
+ "uint64": {
143
+ "float64": 0,
144
+ "float32": 0,
145
+ "float16": 0,
146
+ "int64": 0,
147
+ "int32": 0,
148
+ "int16": 0,
149
+ "int8": 0,
150
+ "uint64": 1,
151
+ "uint32": 1,
152
+ "uint16": 1,
153
+ "uint8": 1,
154
+ "uint8c": 1,
155
+ "complex128": 1,
156
+ "complex64": 0,
157
+ "complex32": 0,
158
+ "binary": 0,
159
+ "generic": 1,
160
+ "bool": 0
161
+ },
162
+ "uint32": {
163
+ "float64": 1,
164
+ "float32": 0,
165
+ "float16": 0,
166
+ "int64": 1,
167
+ "int32": 0,
168
+ "int16": 0,
169
+ "int8": 0,
170
+ "uint64": 1,
171
+ "uint32": 1,
172
+ "uint16": 1,
173
+ "uint8": 1,
174
+ "uint8c": 1,
175
+ "complex128": 1,
176
+ "complex64": 0,
177
+ "complex32": 0,
178
+ "binary": 0,
179
+ "generic": 1,
180
+ "bool": 0
181
+ },
182
+ "uint16": {
183
+ "float64": 1,
184
+ "float32": 1,
185
+ "float16": 0,
186
+ "int64": 1,
187
+ "int32": 1,
188
+ "int16": 0,
189
+ "int8": 0,
190
+ "uint64": 1,
191
+ "uint32": 1,
192
+ "uint16": 1,
193
+ "uint8": 1,
194
+ "uint8c": 1,
195
+ "complex128": 1,
196
+ "complex64": 1,
197
+ "complex32": 0,
198
+ "binary": 0,
199
+ "generic": 1,
200
+ "bool": 0
201
+ },
202
+ "uint8": {
203
+ "float64": 1,
204
+ "float32": 1,
205
+ "float16": 1,
206
+ "int64": 1,
207
+ "int32": 1,
208
+ "int16": 1,
209
+ "int8": 0,
210
+ "uint64": 1,
211
+ "uint32": 1,
212
+ "uint16": 1,
213
+ "uint8": 1,
214
+ "uint8c": 1,
215
+ "complex128": 1,
216
+ "complex64": 1,
217
+ "complex32": 1,
218
+ "binary": 0,
219
+ "generic": 1,
220
+ "bool": 0
221
+ },
222
+ "uint8c": {
223
+ "float64": 1,
224
+ "float32": 1,
225
+ "float16": 1,
226
+ "int64": 1,
227
+ "int32": 1,
228
+ "int16": 1,
229
+ "int8": 0,
230
+ "uint64": 1,
231
+ "uint32": 1,
232
+ "uint16": 1,
233
+ "uint8": 1,
234
+ "uint8c": 1,
235
+ "complex128": 1,
236
+ "complex64": 1,
237
+ "complex32": 1,
238
+ "binary": 0,
239
+ "generic": 1,
240
+ "bool": 0
241
+ },
242
+ "complex128": {
243
+ "float64": 0,
244
+ "float32": 0,
245
+ "float16": 0,
246
+ "int64": 0,
247
+ "int32": 0,
248
+ "int16": 0,
249
+ "int8": 0,
250
+ "uint64": 0,
251
+ "uint32": 0,
252
+ "uint16": 0,
253
+ "uint8": 0,
254
+ "uint8c": 0,
255
+ "complex128": 1,
256
+ "complex64": 1,
257
+ "complex32": 1,
258
+ "binary": 0,
259
+ "generic": 0,
260
+ "bool": 0
261
+ },
262
+ "complex64": {
263
+ "float64": 0,
264
+ "float32": 0,
265
+ "float16": 0,
266
+ "int64": 0,
267
+ "int32": 0,
268
+ "int16": 0,
269
+ "int8": 0,
270
+ "uint64": 0,
271
+ "uint32": 0,
272
+ "uint16": 0,
273
+ "uint8": 0,
274
+ "uint8c": 0,
275
+ "complex128": 1,
276
+ "complex64": 1,
277
+ "complex32": 1,
278
+ "binary": 0,
279
+ "generic": 0,
280
+ "bool": 0
281
+ },
282
+ "complex32": {
283
+ "float64": 0,
284
+ "float32": 0,
285
+ "float16": 0,
286
+ "int64": 0,
287
+ "int32": 0,
288
+ "int16": 0,
289
+ "int8": 0,
290
+ "uint64": 0,
291
+ "uint32": 0,
292
+ "uint16": 0,
293
+ "uint8": 0,
294
+ "uint8c": 0,
295
+ "complex128": 1,
296
+ "complex64": 1,
297
+ "complex32": 1,
298
+ "binary": 0,
299
+ "generic": 0,
300
+ "bool": 0
301
+ },
302
+ "generic": {
303
+ "float64": 0,
304
+ "float32": 0,
305
+ "float16": 0,
306
+ "int64": 0,
307
+ "int32": 0,
308
+ "int16": 0,
309
+ "int8": 0,
310
+ "uint64": 0,
311
+ "uint32": 0,
312
+ "uint16": 0,
313
+ "uint8": 0,
314
+ "uint8c": 0,
315
+ "complex128": 0,
316
+ "complex64": 0,
317
+ "complex32": 0,
318
+ "binary": 0,
319
+ "generic": 1,
320
+ "bool": 0
321
+ },
322
+ "binary": {
323
+ "float64": 0,
324
+ "float32": 0,
325
+ "float16": 0,
326
+ "int64": 0,
327
+ "int32": 0,
328
+ "int16": 0,
329
+ "int8": 0,
330
+ "uint64": 0,
331
+ "uint32": 0,
332
+ "uint16": 0,
333
+ "uint8": 0,
334
+ "uint8c": 0,
335
+ "complex128": 0,
336
+ "complex64": 0,
337
+ "complex32": 0,
338
+ "binary": 1,
339
+ "generic": 0,
340
+ "bool": 0
341
+ },
342
+ "bool": {
343
+ "float64": 0,
344
+ "float32": 0,
345
+ "float16": 0,
346
+ "int64": 0,
347
+ "int32": 0,
348
+ "int16": 0,
349
+ "int8": 0,
350
+ "uint64": 0,
351
+ "uint32": 0,
352
+ "uint16": 0,
353
+ "uint8": 0,
354
+ "uint8c": 0,
355
+ "complex128": 0,
356
+ "complex64": 0,
357
+ "complex32": 0,
358
+ "binary": 0,
359
+ "generic": 1,
360
+ "bool": 1
361
+ }
197
362
  }
package/manifest.json CHANGED
@@ -1,38 +1,38 @@
1
1
  {
2
- "options": {},
3
- "fields": [
4
- {
5
- "field": "src",
6
- "resolve": true,
7
- "relative": true
8
- },
9
- {
10
- "field": "include",
11
- "resolve": true,
12
- "relative": true
13
- },
14
- {
15
- "field": "libraries",
16
- "resolve": false,
17
- "relative": false
18
- },
19
- {
20
- "field": "libpath",
21
- "resolve": true,
22
- "relative": false
23
- }
24
- ],
25
- "confs": [
26
- {
27
- "src": [],
28
- "include": [
29
- "./include"
30
- ],
31
- "libraries": [],
32
- "libpath": [],
33
- "dependencies": [
34
- "@stdlib/ndarray-dtypes"
35
- ]
36
- }
37
- ]
2
+ "options": {},
3
+ "fields": [
4
+ {
5
+ "field": "src",
6
+ "resolve": true,
7
+ "relative": true
8
+ },
9
+ {
10
+ "field": "include",
11
+ "resolve": true,
12
+ "relative": true
13
+ },
14
+ {
15
+ "field": "libraries",
16
+ "resolve": false,
17
+ "relative": false
18
+ },
19
+ {
20
+ "field": "libpath",
21
+ "resolve": true,
22
+ "relative": false
23
+ }
24
+ ],
25
+ "confs": [
26
+ {
27
+ "src": [],
28
+ "include": [
29
+ "./include"
30
+ ],
31
+ "libraries": [],
32
+ "libpath": [],
33
+ "dependencies": [
34
+ "@stdlib/ndarray-dtypes"
35
+ ]
36
+ }
37
+ ]
38
38
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stdlib/ndarray-same-kind-casts",
3
- "version": "0.2.1",
3
+ "version": "0.4.0",
4
4
  "description": "Return a list of ndarray data types to which a provided ndarray data type can be safely cast or cast within the same kind.",
5
5
  "license": "Apache-2.0",
6
6
  "author": {
@@ -31,10 +31,10 @@
31
31
  "url": "https://github.com/stdlib-js/stdlib/issues"
32
32
  },
33
33
  "dependencies": {
34
- "@stdlib/assert-has-own-property": "^0.2.1",
35
- "@stdlib/ndarray-base-dtype-resolve-str": "^0.2.1",
36
- "@stdlib/ndarray-dtypes": "^0.2.1",
37
- "@stdlib/utils-keys": "^0.2.1"
34
+ "@stdlib/assert-has-own-property": "^0.2.2",
35
+ "@stdlib/ndarray-base-dtype-resolve-str": "^0.2.2",
36
+ "@stdlib/ndarray-dtypes": "^0.3.0",
37
+ "@stdlib/utils-keys": "^0.2.2"
38
38
  },
39
39
  "devDependencies": {},
40
40
  "engines": {
@@ -66,7 +66,6 @@
66
66
  "utils",
67
67
  "util"
68
68
  ],
69
- "__stdlib__": {},
70
69
  "funding": {
71
70
  "type": "opencollective",
72
71
  "url": "https://opencollective.com/stdlib"