I am attempting to convert a simple Swift application (here) from using a Swift data model to a C++ model. I found an article (here) on wrapping C++ code with Obj-C++ in order to expose the C++ model to Swift.
I have completed the conversion and have no compiler warnings/errors until I place my Obj-C++ "wrapper" header into the <xx>-Bridging-Header.h. Inside the bridging header I have a single #include to my Obj-C++ "wrapper" header file. That Obj-C++ wrapper class of course links directly to my C++ class header. When attempting to compile, I get an error from Swift that <unordered_map> is unable to be found.
This makes sense as I wouldn't expect Swift to know anything about C++ or any of its headers. I thought the point of the bridging header was for the Obj-C++ compiler to be able to kick in and compile the code appropriately.
In Build settings I ensured that the C++11 compiler flag was being used under the LLVM 6.0 C++ compiler settings. However, it doesn't seem that any compiler other than the Swift one is being used. And, removing the <unordered_map> dependency from the C++ header it then cannot find <vector>, so I am confident this has nothing to do with C++ 11.
If anyone can point me in the right direction here it would be greatly appreciated!