How can I use C++ 11 features in Clang?

后端 未结 2 1082
谎友^
谎友^ 2020-11-29 22:35

How can I use the latest C++ 11 features in Clang? What (sub)set of features is supported?

2条回答
  •  忘掉有多难
    2020-11-29 23:23

    Here is the always up to date list of features supported by clang:

    http://clang.llvm.org/cxx_status.html

    To activate C++11, you have to add -std=c++11 in your clang calls, like for gcc. If you use an IDE that is clang-aware or gcc-aware, there is a specific project settings option available to do that.

提交回复
热议问题