Commit 1d0b3e33 authored by Stefan Behnel's avatar Stefan Behnel

cleanup

parent 940883b0
...@@ -2121,11 +2121,11 @@ class DefNode(FuncDefNode): ...@@ -2121,11 +2121,11 @@ class DefNode(FuncDefNode):
code.putln('}') code.putln('}')
# now fill up the required arguments with values from the kw dict # now fill up the required arguments with values from the kw dict
last_required_arg = -1 if self.num_required_args:
for i, arg in enumerate(all_args): last_required_arg = -1
if not arg.default: for i, arg in enumerate(all_args):
last_required_arg = i if not arg.default:
if last_required_arg >= 0: last_required_arg = i
code.putln('switch (PyTuple_GET_SIZE(%s)) {' % Naming.args_cname) code.putln('switch (PyTuple_GET_SIZE(%s)) {' % Naming.args_cname)
for i, arg in enumerate(all_args[:last_required_arg+1]): for i, arg in enumerate(all_args[:last_required_arg+1]):
if i <= max_positional_args: if i <= max_positional_args:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment