Qt support for C++0x enum class

冷暖自知 提交于 2019-12-23 18:34:28

问题


Using Q_ENUMS I can now "register" with Qt an enum declared inside a class that inherists from QObject. This gives me a few cool reflection features for the enum.

I'm also really enjoying the type-safe enum class introduced in C++0x. I'm wondering if you know of any announcement made by Qt developers of plans for support for the enum class.

This question vaguely asks about Qt support of C++0x features in general. I'm asking specifically about enum class. I realize that since Qt is cross-platform and supports many compilers, support for C++0x will be SLOW to roll out, but enum class is a very nice simple improvement of the core language!


回答1:


It appears that Qt 4.8 will have support for many major C++0x features (including enum class) according to this blog post.



来源:https://stackoverflow.com/questions/6513736/qt-support-for-c0x-enum-class

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!