Use Q_GLOBAL_STATIC where K_GLOBAL_STATIC is not needed?

Michael Pyne mpyne at kde.org
Wed Feb 16 02:37:08 GMT 2011


On Tuesday, February 15, 2011 08:11:23 Thiago Macieira wrote:
> > That would be exceedingly nice, yes. I would at least feel less bad
> > about my current usage of QBasicAtomicInt (on non-PA-RISC), especially
> > if the statement about being POD and non-POD were also to be explicitly
> > added to the API.
> 
> Meanwhile, you should initialise with Q_BASIC_ATOMIC_INITIALIZER(0).

Well, the use case here is that the zero-filled memory given by mmap/ftruncate 
on a new file should be immediately usable.

I suppose I could see about using GCC intrinsics or something instead if that 
will be an issue.

Regards,
 - Michael Pyne
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20110215/aca64668/attachment.sig>


More information about the kde-core-devel mailing list