[pypy-commit] pypy virtual-arguments: another small simplification
cfbolz
noreply at buildbot.pypy.org
Mon Apr 16 11:46:40 CEST 2012
Author: Carl Friedrich Bolz <cfbolz at gmx.de>
Branch: virtual-arguments
Changeset: r54400:c48491599f51
Date: 2012-04-14 12:00 +0200
http://bitbucket.org/pypy/pypy/changeset/c48491599f51/
Log: another small simplification
diff --git a/pypy/interpreter/argument.py b/pypy/interpreter/argument.py
--- a/pypy/interpreter/argument.py
+++ b/pypy/interpreter/argument.py
@@ -243,13 +243,11 @@
# so all values coming from there can be assumed constant. It assumes
# that the length of the defaults_w does not vary too much.
co_argcount = signature.num_argnames() # expected formal arguments, without */**
- input_argcount = 0
if w_firstarg is not None:
upfront = 1
if co_argcount > 0:
scope_w[0] = w_firstarg
- input_argcount = 1
else:
upfront = 0
@@ -263,6 +261,7 @@
num_kwds = len(keywords)
+ input_argcount = upfront
if input_argcount < co_argcount:
# put as many positional input arguments into place as available
take = min(num_args, co_argcount - upfront)
More information about the pypy-commit
mailing list