[New-bugs-announce] [issue16856] Segfault from calling repr() on a dict with a key whose repr raise an exception

David M. Cooke report at bugs.python.org
Fri Jan 4 00:30:51 CET 2013


New submission from David M. Cooke:

The following segfaults:

class A(int):
    def __repr__(self):
        raise Exception()
a = A()
d = {a : 1}
repr(d)

This is with Python 3.3.0, running on Mac OS 10.7.5, from MacPorts:
Python 3.3.0 (default, Sep 29 2012, 08:16:08) 
[GCC 4.2.1 Compatible Apple Clang 3.1 (tags/Apple/clang-318.0.58)] on darwin

----------
components: Interpreter Core
messages: 178997
nosy: david.m.cooke
priority: normal
severity: normal
status: open
title: Segfault from calling repr() on a dict with a key whose repr raise an exception
type: crash
versions: Python 3.3

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16856>
_______________________________________


More information about the New-bugs-announce mailing list