[Development] QLatin1Constant and QtContacts / QtOrganizer

Stephen Kelly stephen.kelly at kdab.com
Tue Jan 10 06:39:29 CET 2012


On Tuesday, December 20, 2011 10:17:20 Thiago Macieira wrote:
>         str = QString::fromLatin1("%1 %2").arg(foo, bar);
>                 reason: QString::fromLatin1 will need to allocate memory
>                 use: QStringLiteral

I looked into QStringLiteral by the way. It has no arg() methods, so if you 
are suggesting

str = QStringLiteral("%1 %2").arg(foo, bar);

that won't work.

Are you suggesting 

str = QString(QStringLiteral("%1 %2")).arg(foo, bar);

or so?

Thanks,

-- 
Stephen Kelly <stephen.kelly at kdab.com> | Software Engineer
KDAB (Deutschland) GmbH & Co.KG, a KDAB Group Company
www.kdab.com || Germany +49-30-521325470 || Sweden (HQ) +46-563-540090
KDAB - Qt Experts - Platform-Independent Software Solutions
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120110/62ad25b3/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120110/62ad25b3/attachment.sig>


More information about the Development mailing list