How do I get the new C++ threading support on Mac OS X with clang?

后端 未结 1 625
予麋鹿
予麋鹿 2021-02-06 06:44

I just want to compile the following program on Mac OSX 10.8 using Apple clang version 4.1 (tags/Apple/clang-421.11.66):

#include 

using namespace         


        
相关标签:
1条回答
  • 2021-02-06 07:17

    You need to use the new libc++, which isn't the default:

    clang++ -stdlib=libc++ threadtest.cpp 
    

    (Of course you also need to include iostream, but I assume that wasn't you confusion.)

    0 讨论(0)
提交回复
热议问题