On Tue, Oct 30, 2012 at 8:21 AM, Andrew Robinson <andr...@r3dsolutions.com> wrote: > D'Apriano mentioned the named values, start, stop, step in a slice() which > are an API and legacy issue; These three names must also be stored in the > interpreter someplace. Since slice is defined at the "C" level as a struct, > have you already found these names in the source code (hard-coded), or are > they part of a .py file associated with the interface to the "C" code?
You mean the mapping of Python attribute names to C struct members? That's in sliceobject.c: static PyMemberDef slice_members[] = { {"start", T_OBJECT, offsetof(PySliceObject, start), READONLY}, {"stop", T_OBJECT, offsetof(PySliceObject, stop), READONLY}, {"step", T_OBJECT, offsetof(PySliceObject, step), READONLY}, {0} }; -- http://mail.python.org/mailman/listinfo/python-list