[New-bugs-announce] [issue18482] dis.dis fails on one letter strings.

James Lu report at bugs.python.org
Wed Jul 17 17:26:08 CEST 2013


New submission from James Lu:

dis.dis fails on one letter strings.
dis.dis("t")
Traceback (most recent call last):
  File "<pyshell#26>", line 1, in <module>
    dis.dis("t")
  File "C:\python 25\lib\dis.py", line 44, in dis
    disassemble_string(x)
  File "C:\python 25\lib\dis.py", line 111, in disassemble_string
    labels = findlabels(code)
  File "C:\python 25\lib\dis.py", line 165, in findlabels
    oparg = ord(code[i]) + ord(code[i+1])*256
IndexError: string index out of range

----------
components: Library (Lib)
messages: 193233
nosy: James.Lu
priority: normal
severity: normal
status: open
title: dis.dis fails on one letter strings.
type: crash
versions: Python 2.7

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


More information about the New-bugs-announce mailing list