Commit 2056a94
authored
Fix optional keyword argument in
This commit fixes the function signature for `take`. Namely, when
an input array is one-dimensional, the `axis` kwarg is optional;
when the array has more than one dimension, the `axis` kwarg is
required. Unfortunately, the type signature cannot encode this
duality, and we must rely on the specification text to clarify
that the `axis` kwarg is required for arrays having ranks greater
than unity.
Ref: data-apis/array-api-compat#34take signature (#644)1 parent 2e0c414 commit 2056a94
File tree
2 files changed
+4
-4
lines changed- src/array_api_stubs
- _2022_12
- _draft
2 files changed
+4
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| |||
0 commit comments