This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug python/17386] New: gdb.Value should have __index__ method


https://sourceware.org/bugzilla/show_bug.cgi?id=17386

            Bug ID: 17386
           Summary: gdb.Value should have __index__ method
           Product: gdb
           Version: unknown
            Status: NEW
          Severity: normal
          Priority: P2
         Component: python
          Assignee: unassigned at sourceware dot org
          Reporter: tromey at sourceware dot org

I've seen multiple reports where a pretty-printer throws an
exception like

Python Exception <class 'TypeError'> 'gdb.Value' object cannot be interpreted
as an integer: 

E.g., https://bugzilla.mozilla.org/show_bug.cgi?id=1058392
... but there are many more if you search for the relevant bits of
the error message.

I think one possible fix is for gdb.Value to implement the __index__
method.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]