On Monday 03 December 2012 00:41:38 Francisco Lopes da Silva wrote:
> I'm trying to build Qt5 on my environment but I'm stumbling at an error I'm
> having a hardtime dealing with.
> I use OS X Mountain Lion, but I don't use the default Xcode environment, I
> compile both clang and libc++
> from sources.

I was able to reproduce the error by making QMetaTypeIdQObject a template.
(On linux with both clang 3.1 and clang trunk)
Attached the problematic testase.

I am not sure yet if this is a compiler bug or if we are indeed doing a copy.

-- 
Olivier

Woboq - Qt services and support - http://woboq.com
 
struct QBasicAtomicInteger
{
    QBasicAtomicInteger(int value)   {}
    QBasicAtomicInteger(const QBasicAtomicInteger &) = delete;
};
 
template<typename T>
struct QMetaTypeIdQObject
{
    static int qt_metatype_id()
    {
        static QBasicAtomicInteger metatype_id = { 0 };
        return 0;
    }
}; 
 
int main()
{
    return QMetaTypeIdQObject<int>::qt_metatype_id();
}
 
_______________________________________________
Development mailing list
[email protected]
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to