On 14 October 2012 20:57, Mike Meyer <firstname.lastname@example.org> wrote:
Yes, but we're defining an operator for instances of the class, so itOn Sun, 14 Oct 2012 07:40:57 +0200
Yuval Greenfield <email@example.com> wrote:
> On Sun, Oct 14, 2012 at 2:04 AM, MRAB <firstname.lastname@example.org> wrote:
> > If it's more than one codepoint, we could prefix with the length of the
> > codepoint's name:
> > def __12CIRCLED_PLUS__(x, y):
> > ...
> That's a bit impractical, and why reinvent the wheel? I'd much rather:
> def \u2295(x, y):
> So readable I want to read it twice. And that's not legal python today so
> we don't break backwards compatibility!
needs the 'special' method marking:
def __\u2295__(self, other):
Now *that's* pretty!