@@ -3013,7 +3013,7 @@ def require(a, dtype=None, requirements=None, *, like=None):
30133013 return arr
30143014
30153015
3016- def reshape (a , / , shape = None , order = "C" , * , newshape = None , copy = None ):
3016+ def reshape (a , / , shape = None , order = "C" , * , copy = None ):
30173017 """
30183018 Gives a new shape to an array without changing its data.
30193019
@@ -3045,10 +3045,6 @@ def reshape(a, /, shape=None, order="C", *, newshape=None, copy=None):
30453045 Fortran *contiguous* in memory, C-like order otherwise.
30463046
30473047 Default: ``"C"``.
3048- newshape : int or tuple of ints
3049- Replaced by `shape` argument. Retained for backward compatibility.
3050-
3051- Default: ``None``.
30523048 copy : {None, bool}, optional
30533049 If ``True``, then the array data is copied. If ``None``, a copy will
30543050 only be made if it's required by ``order``. For ``False`` it raises
@@ -3117,27 +3113,11 @@ def reshape(a, /, shape=None, order="C", *, newshape=None, copy=None):
31173113
31183114 """
31193115
3120- if newshape is None and shape is None :
3116+ if shape is None :
31213117 raise TypeError (
31223118 "reshape() missing 1 required positional argument: 'shape'"
31233119 )
31243120
3125- if newshape is not None :
3126- if shape is not None :
3127- raise TypeError (
3128- "You cannot specify 'newshape' and 'shape' arguments "
3129- "at the same time."
3130- )
3131- # Deprecated in dpnp 0.17.0
3132- warnings .warn (
3133- "`newshape` keyword argument is deprecated, "
3134- "use `shape=...` or pass shape positionally instead. "
3135- "(deprecated in dpnp 0.17.0)" ,
3136- DeprecationWarning ,
3137- stacklevel = 2 ,
3138- )
3139- shape = newshape
3140-
31413121 if order is None :
31423122 order = "C"
31433123 elif order in "aA" :
0 commit comments