diff options
author | Eric Wieser <wieser.eric@gmail.com> | 2020-01-06 01:50:02 +0000 |
---|---|---|
committer | Eric Wieser <wieser.eric@gmail.com> | 2020-01-06 12:51:55 +0000 |
commit | b6379539924568dad725f2ecc820477685f8d938 (patch) | |
tree | c0516e000911eebe166884a90b12140eac46d187 /numpy/doc | |
parent | ba81c4200f289b393755d954f7450804ec8f897a (diff) | |
download | numpy-b6379539924568dad725f2ecc820477685f8d938.tar.gz |
MAINT: Implement keyword-only arguments as syntax
Now that 2.7 is gone, there is no need to pop manually from kwarg dictionaries.
Diffstat (limited to 'numpy/doc')
-rw-r--r-- | numpy/doc/subclassing.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/numpy/doc/subclassing.py b/numpy/doc/subclassing.py index bfc01bdc6..5a54ddd90 100644 --- a/numpy/doc/subclassing.py +++ b/numpy/doc/subclassing.py @@ -454,7 +454,7 @@ following. input numpy as np class A(np.ndarray): - def __array_ufunc__(self, ufunc, method, *inputs, **kwargs): + def __array_ufunc__(self, ufunc, method, *inputs, out=None, **kwargs): args = [] in_no = [] for i, input_ in enumerate(inputs): @@ -464,7 +464,7 @@ following. else: args.append(input_) - outputs = kwargs.pop('out', None) + outputs = out out_no = [] if outputs: out_args = [] |