New issue 2113: Calling str.expandtabs(0) crashes with a floating point exception https://bitbucket.org/pypy/pypy/issues/2113/calling-strexpandtabs-0-crashes-with-a
Jason Madden: In PyPy 2.5.0, 2.6.0 and a recent 2.7 build, under both OS X and 64-bit Linux, using `expandtabs(0)` on either a byte string or unicode string crashes with a floating point exception (8). This is very easy to reproduce: ``` $ bin/pypy-2.6-linux_x86_64-portable/bin/pypy Python 2.7.9 (295ee98b69288471b0fcf2e0ede82ce5209eb90b, Jun 01 2015, 17:30:13) [PyPy 2.6.0 with GCC 4.9.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>>> t = u'strict digraph {\n\t1 -> 2;\n\t2 -> 3;\n}\n' >>>> t.expandtabs(0) Floating point exception $ ``` The OS X crash report states that it's of type ``EXC_ARITHMETIC`` and code ``EXC_I386_DIV (division by zero)``. This was noticed during the unittests for pygraphviz. _______________________________________________ pypy-issue mailing list pypy-issue@python.org https://mail.python.org/mailman/listinfo/pypy-issue