Skip to content

Commit ac20ed5

Browse files
committed
fix: export array
1 parent e4673de commit ac20ed5

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

spec/draft/API_specification/array_object.rst

+1-1
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ Methods
275275
Array.__abs__
276276
Array.__add__
277277
Array.__and__
278-
Array.__Array_namespace__
278+
Array.__array_namespace__
279279
Array.__bool__
280280
Array.__complex__
281281
Array.__dlpack__

src/array_api_stubs/_draft/_types.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"Union",
2020
"Sequence",
2121
"array",
22+
"Array",
2223
"device",
2324
"dtype",
2425
"ellipsis",
@@ -46,7 +47,7 @@
4647
from enum import Enum
4748
from .data_types import DType
4849

49-
array = TypeVar("array", bound="_array")
50+
array = TypeVar("array", bound="Array")
5051
device = TypeVar("device")
5152
dtype = TypeVar("dtype", bound=DType)
5253
device_ = TypeVar("device_") # only used in this file
@@ -149,7 +150,7 @@ def dtypes(
149150
)
150151

151152

152-
class _array(Protocol[array, dtype_, device_, PyCapsule]): # type: ignore
153+
class Array(Protocol[array, dtype_, device_, PyCapsule]): # type: ignore
153154
def __init__(self: array) -> None:
154155
"""Initialize the attributes for the array object class."""
155156

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
from ._types import array
1+
from ._types import array, Array
22

3-
__all__ = ["array"]
3+
__all__ = ["array", "Array"]

0 commit comments

Comments
 (0)