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

List:       kde-commits
Subject:    Re: kdegames/atlantik
From:       Rob Kaper <cap () capsi ! com>
Date:       2004-01-28 8:02:49
Message-ID: 20040128090249.B15633 () capsi ! com
[Download RAW message or body]


On Wed, Jan 28, 2004 at 01:00:53AM +0100, Andy Goossens wrote:
> > QString::find is faster than ::contains
> >
> > -        if (text.contains("rolls"))
> > +        if ( text.find( QRegExp("rolls") ) != -1 )
> 
> Even with a useless QRegExp?

It's the "default" method for QString::find, the others are overloaded and
provided for convenience only, so I assume ::find will at some point have to
use a QRegExp for its mojo anyway.

Rob
-- 
Rob Kaper     | 1/28 The Rasmus, 2/17 Blink-182, 2/29 Anti-Flag
cap@capsi.com | 3/5  Anti-Flag/Heideroosjes, 3/19 The Offspring
www.capsi.com | 3/24 Good Riddance/None More Black, 5/14 Disney

[Attachment #3 (application/pgp-signature)]

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

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