Although I could not reproduce Bug 966, I found lots of unit tests that failed to compile in C++11 mode. Also, currently building (everything) in C++11 mode requires some manual flag settings: cmake .. -DEIGEN_BUILD_STRING_SUFFIX=cxx11 -DEIGEN_TEST_CUSTOM_CXX_FLAGS=-std=c++11 We could set that flag automatically (and modify the BUILD_STRING) whenever EIGEN_TEST_CXX11 is activated. The old EIGEN_TEST_C++0x only works for g++, and I'd vote for deprecating (or entirely removing) it.
arf, I've been confused myself with EIGEN_TEST_CXX11. I assumed it added -std=c++11 everywhere, so yes having EIGEN_TEST_CXX11 => EIGEN_TEST_CUSTOM_CXX_FLAGS=-std=c++11 is probably a good idea. I also agree that EIGEN_TEST_C++0x should be removed.
My local fix consists in defining internal::result_of as follow in C++11: template<typename T> struct result_of { typedef typename std::result_of<T>::type type1; typedef typename remove_all<type1>::type type; }; This change allowed me to find a few situations where we instantiated result_of<Func(arg)> on binary functors! Still a few issues to fix before committing.
https://bitbucket.org/eigen/eigen/commits/c250623ae9fa/ Summary: Fix some calls to result_of on binary functors as unary ones. https://bitbucket.org/eigen/eigen/commits/1d76db2d5524/ Summary: Fix a C++11 compilation issue in unit test https://bitbucket.org/eigen/eigen/commits/a1bdc556d832/ Summary: Fix regression with C++11 support of lambda: now internal::result_of falls back to std::result_of in C++11. Still have to update the CMake stuff....
https://bitbucket.org/eigen/eigen/commits/777b6c45ec52/ Summary: Remove EIGEN_TEST_C++0x option and let EIGEN_TEST_CXX11 adds the -std=c++11 flag
There were two issues left, which I fixed here: https://bitbucket.org/eigen/eigen/commits/bb202c68 https://bitbucket.org/eigen/eigen/commits/1cab4106 Furthermore, we now have lots of deprecation warnings for binder1st and binder2nd. As far as I can see, they are only used for comparison operators, which should get replaced in order to solve Bug 97, eventually. Also: Shall we automatically add a build string suffix when compiling in C++11 mode? (or when compiling in C++03 mode, if C++11 becomes default?)
-- GitLab Migration Automatic Message -- This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/967.