Registered Member
|
In one of my projects, I recently upgraded Eigen to v. 3.2.8, and when building in XCode 7.3.1, I now get several errors like these: ...../Eigen/eigen/Eigen/src/Core/DenseStorage.h:277:21: No member named 'move' in namespace 'std'; did you mean 'modf'?
Do I need a specific compiler version to build in XCode? I also noticed there is a preprocessor definition EIGEN_HAVE_RVALUE_REFERENCES that is #ifdef'd upon. A C++ 11 move semantics thing I guess? Does Eigen build without C++ 11 support? Should I undefine that macro somewhere? And does this have relevant speed implications? Koen |
Moderator
|
I've xcode 7.3.0 but cannot reproduce. Could you paste your compiler flags? In particular does it includes -std=c++11? Finally, what if you add:
#include <utility> before including any Eigen's header? |
Registered Member
|
Thanks for the fast follow-up!
Under the Apple LLVM 7.1 - Language - C++ settings, the C++ Language Dialect was set to C++11 [-std=c++11] . However, C++ Standard Library was set to Compiler Default, which appears to be libstdc++ (GNU C++ standard library). When I changed this to libc++ (LLVM C++ standard library with C++ 11 support), the errors went away and the Eigen code built just fine. Also, if I changed C++ Language Dialect to -std=gnu++98, and C++ standard library to libstdc++, the errors also disappear. So it was just a configuration issue in my Xcode project and all is fine with Eigen! Koen |
Moderator
|
Indeed, libstdc++ does not support c++11
|
Registered users: Bing [Bot], blue_bullet, Google [Bot], rockscient, Yahoo [Bot]