This is the mail archive of the
gdb@sourceware.org
mailing list for the GDB project.
Python: should gdb.Value array indexing check bounds?
- From: <Paul_Koning at Dell dot com>
- To: <gdb at sourceware dot org>
- Date: Tue, 20 Sep 2011 11:04:59 -0500
- Subject: Python: should gdb.Value array indexing check bounds?
Currently, if a gdb.Value object corresponds to an array, array indexing is done C-style: no bounds checking, just pointer arithmetic.? That's somewhat unnatural to Python.? Should it do a range check instead, and raise IndexError for out of range index values?
That wouldn't affect indexing of pointers, since those don't have a range so the only possible approach is the C one.
??????????????? paul