@@ -127,7 +127,6 @@ def wrapped(*args, **kwds):
127
127
# loop over positional parameters and actual arguments
128
128
lst , dct = [], {}
129
129
for arg , (name , parm ) in zip (args , sig .parameters .items ()):
130
- print (arg , name , parm .annotation )
131
130
lst .append (normalize_this (arg , parm , return_on_failure ))
132
131
133
132
# normalize keyword arguments
@@ -138,7 +137,6 @@ def wrapped(*args, **kwds):
138
137
f"{ func .__name__ } () got an unexpected keyword argument '{ name } '."
139
138
)
140
139
141
- print ("kw: " , name , sig .parameters [name ].annotation )
142
140
parm = sig .parameters [name ]
143
141
dct [name ] = normalize_this (arg , parm , return_on_failure )
144
142
@@ -152,20 +150,6 @@ def wrapped(*args, **kwds):
152
150
raise TypeError (
153
151
f"{ func .__name__ } () takes { len (ba .args )} positional argument but { len (args )} were given."
154
152
)
155
-
156
- # TODO:
157
- # 1. [LOOKS OK] kw-only parameters : see vstack
158
- # 2. [LOOKS OK] extra unknown args -- error out : nonzero([2, 0, 3], oops=42)
159
- # 3. [LOOKS OK] optional (tensor_or_none) : untyped => pass through
160
- # 4. [LOOKS OK] DTypeLike : positional or kw
161
- # 5. axes : live in _impl or in types? several ways of handling them
162
- # 6. [OK, NOT HERE] keepdims : peel off, postprocess
163
- # 7. OutLike : normal & keyword-only, peel off, postprocess
164
- # 8. [LOOKS OK] *args
165
- # 9. [LOOKS OK] consolidate normalizations (_funcs, _wrapper)
166
- # 10. [LOOKS OK] consolidate decorators (_{unary,binary}_ufuncs)
167
- # 11. out= arg : validate it's an ndarray
168
-
169
153
# finally, pass normalized arguments through
170
154
result = func (* ba .args , ** ba .kwargs )
171
155
return result
0 commit comments