Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

in Xcode LLVM C++ standard library with c++11 support #120

Closed
CoderAndCat opened this issue Jan 29, 2021 · 3 comments
Closed

in Xcode LLVM C++ standard library with c++11 support #120

CoderAndCat opened this issue Jan 29, 2021 · 3 comments

Comments

@CoderAndCat
Copy link

in Xcode LLVM C++ standard library with c++11 support and c++ 17 Language.
Which tag is suitable for use in xcode?

@webern
Copy link
Owner

webern commented Jan 29, 2021

Are you using the checked-in Xcode project? I think it might be broken currently by an update in Xcode #119.

But you should be able to generate a working Xcode project using CMake.
cmake -G Xcode .
https://stackoverflow.com/a/41830798/2779792

Edit: this might answer your question more directly... C++17 features are needed because I used std::optional.

@CoderAndCat
Copy link
Author

I want to us mx in my iOS project as static library. but wrong!
截屏2021-01-31 下午12 16 54

@webern
Copy link
Owner

webern commented Jan 31, 2021

Are you using an Objective C++ file as a bridge to swift? I found this which suggests that the problem could be that you are using Objective-C instead of Objective-C++. https://stackoverflow.com/a/54498903

I don't know how to bridge between C++ and Swift, but it seems like that is the source of the problem. The header file you pictured is being evaluated in C instead of C++.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants