Hi, A recent patch to clang enables a warning for any use of the register storage class specifier when -std=c++11 is used.
$ ~/dev/build/qtbase/llvm/bin/clang++ -std=c++11 -fPIE -
I$HOME/dev/prefix/qtbase/include -c
~/dev/src/qtbase/src/corelib/tools/qstring.h
clang-3.4: warning: treating 'c-header' input as 'c++-header' when in C++
mode, this behavior is deprecated
In file included from
/home/stephen/dev/src/qtbase/src/corelib/tools/qstring.h:45:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qchar.h:45:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qglobal.h:987:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qglobalstatic.h:47:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qatomic.h:47:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qbasicatomic.h:84:
In file included from
/home/stephen/dev/prefix/qtbase/include/QtCore/qatomic_x86.h:46:
/home/stephen/dev/prefix/qtbase/include/QtCore/qgenericatomic.h:175:13:
warning: 'register' storage class specifier is deprecated [-Wdeprecated]
register T tmp = load(_q_value);
^~~~~~~~~
/home/stephen/dev/prefix/qtbase/include/QtCore/qgenericatomic.h:210:13:
warning: 'register' storage class specifier is deprecated [-Wdeprecated]
register T tmp = BaseClass::load(_q_value);
^~~~~~~~~
http://thread.gmane.org/gmane.comp.compilers.clang.scm/74932
This will be quite noisy for Qt and for users of Qt. Should we remove the use
of register from Qt? Or replace it with Q_REGISTER which is empty for c++11?
Thanks,
--
Stephen Kelly <[email protected]> | 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
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Development mailing list [email protected] http://lists.qt-project.org/mailman/listinfo/development
