File tree Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Expand file tree Collapse file tree 3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -831,7 +831,7 @@ def _device_ctx(
831831 raise AssertionError ("unreachable" ) # pragma: nocover
832832
833833
834- def _validate_device (bare_xp : Namespace , device : Device ) -> None :
834+ def _check_device (bare_xp : Namespace , device : Device ) -> None :
835835 with _device_ctx (bare_xp , device ):
836836 pass
837837
Original file line number Diff line number Diff line change @@ -56,7 +56,7 @@ def astype(
5656 specification for more details.
5757 """
5858 # TODO: respect device keyword?
59- _helpers ._validate_device (da , device )
59+ _helpers ._check_device (da , device )
6060
6161 if not copy and dtype == x .dtype :
6262 return x
@@ -87,7 +87,7 @@ def arange(
8787 specification for more details.
8888 """
8989 # TODO: respect device keyword?
90- _helpers ._validate_device (da , device )
90+ _helpers ._check_device (da , device )
9191
9292 args = [start ]
9393 if stop is not None :
@@ -157,7 +157,7 @@ def asarray(
157157 specification for more details.
158158 """
159159 # TODO: respect device keyword?
160- _helpers ._validate_device (da , device )
160+ _helpers ._check_device (da , device )
161161
162162 if isinstance (obj , da .Array ):
163163 if dtype is not None and dtype != obj .dtype :
Original file line number Diff line number Diff line change @@ -95,7 +95,7 @@ def asarray(
9595 See the corresponding documentation in the array library and/or the array API
9696 specification for more details.
9797 """
98- _helpers ._validate_device (np , device )
98+ _helpers ._check_device (np , device )
9999
100100 if hasattr (np , '_CopyMode' ):
101101 if copy is None :
@@ -121,7 +121,7 @@ def astype(
121121 copy : bool = True ,
122122 device : Optional [Device ] = None ,
123123) -> Array :
124- _helpers ._validate_device (np , device )
124+ _helpers ._check_device (np , device )
125125 return x .astype (dtype = dtype , copy = copy )
126126
127127
You can’t perform that action at this time.
0 commit comments