[Python-Dev] marshal / unmarshal

Scott David Daniels Scott.Daniels at Acm.Org
Sat Apr 9 01:15:39 CEST 2005


What should marshal / unmarshal do with floating point NaNs (the case we
are worrying about is Infinity) ?  The current behavior is not perfect.

Michael Spencer chased down a supposed "Idle" problem to (on Win2k):
     marshal.dumps(1e10000) == 'f\x061.#INF'
     marshal.loads('f\x061.#INF') == 1.0

Should loads raise an exception?
Somehow, I thing 1.0 is not the best possible representation for +Inf.

-- Scott David Daniels
Scott.Daniels at Acm.Org



More information about the Python-Dev mailing list