[Numpy-discussion] Possible new multiplication operators for Python

Ondrej Certik ondrej@certik...
Sun Aug 17 17:00:51 CDT 2008

On Sun, Aug 17, 2008 at 7:03 AM, Fernando Perez <fperez.net@gmail.com> wrote:
> Hi all,
> [ please keep all replies to this only on the numpy list.  I'm cc'ing
> the scipy ones to make others aware of the topic, but do NOT reply on
> those lists so we can have an organized thread for future reference]
> In the Python-dev mailing lists, there were recently two threads
> regarding the possibility of adding to the language new multiplication
> operators (amongst others).  This would allow one to define things
> like an element-wise and a matrix product for numpy arrays, for
> example:
> http://mail.python.org/pipermail/python-dev/2008-July/081508.html
> http://mail.python.org/pipermail/python-dev/2008-July/081551.html
> It turns out that there's an old pep on this issue:
> http://www.python.org/dev/peps/pep-0225/
> which hasn't been ruled out, simply postponed.  At this point it seems
> that there is room for some discussion, and obviously the input of the
> numpy/scipy crowd would be very welcome.  I volunteered to host a BOF
> next week at scipy so we could collect feedback from those present,
> but it's important that those NOT present at the conference can
> equally voice their ideas/opinions.
> So I wanted to open this thread here to collect feedback.  We'll then
> try to have the bof next week at the conference, and I'll summarize
> everything for python-dev.  Obviously this doesn't mean that we'll get
> any changes in, but at least there's interest in discussing a topic
> that has been dear to everyone here.

I like that Python is so easy to learn, so I hope no more operators
and definitely not unicode operators will be added. And if, then only
if they are really needed, which I think they are not. What I like on
Python is that I can remember all it's syntax in my memory. The more
operators, the more difficult this will be.

There is some inconsistency though, for example one can override A() +
A(), but one cannot override 1 + 1. This could (should) be fixed
somehow. But apart from that, I very much like Python as it is now and
I hope it will not become a bloated language.


More information about the Numpy-discussion mailing list