Wolfgang Maier added the comment:
@serhiy.storchaka you've beaten me by a few minutes (still waiting for the test
suite to finish). Your patch is "contaminated" by an additional change in
collections/__init__.py though so I'm still uploading my version (which also
tries
Changes by Wolfgang Maier :
--
nosy: +vinay.sajip
___
Python tracker
<http://bugs.python.org/issue28637>
___
___
Python-bugs-list mailing list
Unsubscribe:
New submission from Wolfgang Maier:
I've spent a bit of time lately trying to optimize the instantiation of
Fractions. This is related to Issue22464, but instead of focusing on
constructing Fractions from ints, my attempts revolve around improving
instantiation from strings, float
Wolfgang Maier added the comment:
sure, I just happened to have the profiling available since I used it to
optimize things. Here's similar microbenchmarks using perf:
STRINGS
===
$ python -m perf timeit -s "from fractions import Fraction"
"
Wolfgang Maier added the comment:
No, I don't think the numeric tower ABC should be replaced by duck-typing. One
of the very reasons the fractions module exists is that it showcases how to use
the numeric tower. If you want a class to be picked up as a Rational it should
be registered as
Wolfgang Maier added the comment:
try this:
parser.add_argument('file', nargs='?', default = argparse.SUPPRESS)
I don't think this is a bug. The default for the default parameter is None so
the behavior is consistent with the documentation.
Wolfgang Maier added the comment:
Well, you *can* change the value at runtime as you are demonstrating in your
script, but you are misunderstanding the effect this will have. It *won't*
cause a reevaluation of an already parsed config file. Instead it will affect
the writing of the p
Changes by Wolfgang Maier :
--
nosy: +wolma
___
Python tracker
<http://bugs.python.org/issue22298>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Wolfgang Maier :
--
nosy: +wolma
___
Python tracker
<http://bugs.python.org/issue18943>
___
___
Python-bugs-list mailing list
Unsubscribe:
201 - 209 of 209 matches
Mail list logo