I note two issues with compiler -std= values in the dmake tool:
"clang++" contains "g++", so with the test for g++ before the test for clang++, CXXFLAGS includes the gnu options when using clang++ - patch attached.
Here, -std is set to gnu++0x or c++0x (not even c++03) but elsewhere in the same file we use -std=c++11 (but not gnu++11 !). If we set std at all, should we not be consistent about which version ?
It just has always been inconsistent. And we were using the legacy aliases because we were (unnecessarily) supporting some ancient compilers for quite a while.
I note two issues with compiler -std= values in the dmake tool:
"clang++" contains "g++", so with the test for g++ before the test for clang++, CXXFLAGS includes the gnu options when using clang++ - patch attached.
Here, -std is set to gnu++0x or c++0x (not even c++03) but elsewhere in the same file we use -std=c++11 (but not gnu++11 !). If we set std at all, should we not be consistent about which version ?
That doesn't read right. As is clang++ gets the g++ options.
The attached patch gives clang++ the correct options.
But why are we forcing a decades old standard and not even using the correct name ?
Thanks for reporting this.
It just has always been inconsistent. And we were using the legacy aliases because we were (unnecessarily) supporting some ancient compilers for quite a while.
I filed https://trac.cppcheck.net/ticket/13375 about it.