Python Feature Request: Allow changing base of member indices to 1
Nick Craig-Wood
nick at craig-wood.com
Sun Apr 15 05:30:06 EDT 2007
Sherm Pendley <spamtrap at dot-app.org> wrote:
> "Paddy" <paddy3118 at googlemail.com> writes:
>
> > Having more than one index start point would be a maintenance
> > nightmare best avoided.
>
> Quite right.
>
> > (It can be done in Perl).
>
> When was the last time you used Perl? It was allowed in Perl 4 and earlier,
> because many Perl users were moving from Awk, which uses an array base of 1.
> Even then, having multiple index start points within a single program wasn't
> the idea; the idea was to allow programs originally written in Awk to be
> ported to Perl with minimal updating.
>
> It was deprecated as of 5.0 though - which was released in '94. It still
> works, for the sake of backwards compatibility, but its use in new code is
> highly discouraged.
I seem to remember from "Programming Perl" that Larry Wall said it was
a serious mistake to add this feature to perl.
If it is a feature too far for perl then it is *definitely* a feature
too far for python ;-)
--
Nick Craig-Wood <nick at craig-wood.com> -- http://www.craig-wood.com/nick
More information about the Python-list
mailing list