Skip to content

Commit d7b8738

Browse files
committed
Address the default integer dtype issue for 32/64-bit Python
Closes gh-151
1 parent bd667d0 commit d7b8738

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

spec/API_specification/creation_functions.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ Convert the input to an array.
6868

6969
- **dtype**: _Optional\[ <dtype> ]_
7070

71-
- output array data type. If `dtype` is `None`, the output array data type must be inferred from the data type(s) in `obj`. Default: `None`.
71+
- output array data type. If `dtype` is `None`, the output array data type must be inferred from the data type(s) in `obj`. If all input values are Python scalars, then if they're all `bool` the output dtype will be `bool`; if they're a mix of `bool`s and `int` the output dtype will be the default integer data type; if they contain `float`s the output dtype will be the default floating-point data type. Default: `None`.
7272

7373
- **device**: _Optional\[ <device> ]_
7474

spec/API_specification/data_types.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
77
A conforming implementation of the array API standard must provide and support the following data types.
88

9-
A conforming implementation of the array API standard must define a default floating-point data type (either `float32` or `float64`), as well as a default data type for an array index (either `int32` or `int64`).
9+
A conforming implementation of the array API standard must define a default floating-point data type (either `float32` or `float64`), as well as a default data type for an array index (either `int32` or `int64`). These default data types must be the same across platforms. The default integer data type may vary depending on whether Python is 32-bit or 64-bit.
1010

1111
```{note}
1212

0 commit comments

Comments
 (0)