[prev in list] [next in list] [prev in thread] [next in thread] 

List:       pykde
Subject:    Re: [PyKDE] QString and + operator
From:       "Phil Thompson" <phil () riverbankcomputing ! co ! uk>
Date:       2005-04-14 8:27:36
Message-ID: 25371.82.68.80.137.1113467256.squirrel () river-bank ! demon ! co ! uk
[Download RAW message or body]

> I'm making a requirement for a project I'm working on to work with QString
> instead of the built-in type as much as possible. Some will obviously
> complain about this, needing to cast to str() to keep some pythonic spirit
> for concatenation, augmented assignment, etc. I remember seeing in this
> message
> (http://mats.imk.fraunhofer.de/pipermail/pykde/2002-November/003954.html)
> that Phil mentioned supporting the '+' operator for mixed types. I imagine
> the problem is determining what to return. Is there still an interest in
> exposing this?

I thought I had implemented it - must have slipped through the cracks. It
will be in the next snapshot.

Note that...

q = QString("foo") + QString("bar")
q = QString("foo") + "bar"

...will both work, but...

s = "foo" + QString("bar")

...will not.

Phil

_______________________________________________
PyKDE mailing list    PyKDE@mats.imk.fraunhofer.de
http://mats.imk.fraunhofer.de/mailman/listinfo/pykde
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic