On 04/04/06 Gareth McCaughan said:

> > It's a minor thing, but it'd be nice to make a method alias for append() on
> > mutable sequences called push(), to go with pop(). 
> 
> That would confuse anyone used to Lisp, where after
> 
>     (defvar foo (list 1 2 3 4))
>     (puch 99 foo)
> 
> the value of FOO is (99 1 2 3 4) rather than (1 2 3 4 99).
> I take no stand on how much not confusing Lispers matters
> to Python 3k.

It would ease transition from Perl, and be consistent in the method naming. If
one is going to use a method obviously taken from the stack ADT, having a
method normally called push() would be less confusing. I know that I found it
so, having both used stacks and Perl. 

I can make a list subclass obviously, but I've always found append() and pop()
one of those arrangements that just makes new Python programmers say, huh?

Mike

-- 
Michael P. Soulier <[EMAIL PROTECTED]>
"Any intelligent fool can make things bigger and more complex... It
takes a touch of genius - and a lot of courage to move in the opposite
direction." --Albert Einstein

Attachment: pgpSGGILtAo2G.pgp
Description: PGP signature

_______________________________________________
Python-3000 mailing list
Python-3000@python.org
http://mail.python.org/mailman/listinfo/python-3000
Unsubscribe: 
http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com

Reply via email to