[Python-Dev] struct module: add OverflowErrors now?
Anthony Baxter
anthony at interlink.com.au
Sat Nov 13 05:35:30 CET 2004
Armin Rigo wrote:
> Hi,
>
> The struct module is too lazy in checking for overflows (it only checks some
> cases on some architectures). See patch #1038854. The question is: can we
> make it strict this late in the 2.4 release process? This *will* break some
> user code; the proof is that it breaks some standard library code, e.g.
> gzip.py, which uses a signed typecode when it really means an unsigned one.
>
> Fixing it in 2.4 would be nice, but on the other hand we could postpone it for
> the 2.5 trunk; people trying 2.5 early will see the problem quickly. We could
> add warnings for 2.4 but that looks overkill. Or we could just go ahead and
> break existing buggy code with 2.4b3. Opinions?
I think I'd prefer to delay it until 2.5. This is going to break a _lot_
of code.
Adding DeprecationWarnings for 2.4 would be more appropriate, imho.
--
Anthony Baxter <anthony at interlink.com.au>
It's never too late to have a happy childhood.
More information about the Python-Dev
mailing list