[Development] check, Mate!

Stephen Kelly stephen.kelly at kdab.com
Mon Jan 9 13:25:47 CET 2012


Hi,

I've just solved a problem with a method called check() on Mac OSX. It was 
quite a head scratcher, so I thought I'd throw some light on it so others are 
aware.

Mac OSX defines an assert header called check() so I was getting error like:

../../../../include/QtCore/../../src/corelib/kernel/qmetatype.h:357: error: 
declaration does not declare anything
../../../../include/QtCore/../../src/corelib/kernel/qmetatype.h:359: error: 
declaration does not declare anything
../../../../include/QtCore/../../src/corelib/kernel/qmetatype.h:361: error: 
expected primary-expression before ???)??? token

The solution was to rename the method in the patch.

http://boost.2283326.n4.nabble.com/Boost-with-Darwin-Mac-gcc-4-0-1-
td2580330.html

So, keep in mind - for portability treat 'check' as an out of bounds name for 
a method or variable.

I have submitted patches for the two uses of check I found in itemviews and 
dbus. There are more in the xcb plugin.

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/20120109/5bc8d208/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 3636 bytes
Desc: not available
URL: <http://lists.qt-project.org/pipermail/development/attachments/20120109/5bc8d208/attachment.bin>


More information about the Development mailing list