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

building uses different standards on Linux vs Windows #5265

Closed
joonicks opened this issue Sep 16, 2021 · 2 comments
Closed

building uses different standards on Linux vs Windows #5265

joonicks opened this issue Sep 16, 2021 · 2 comments

Comments

@joonicks
Copy link
Contributor

git builds at least seems to use C++11 for Linux builds but C++17 for Windows builds.

unknown to me if the different standards could cause issues, but from a developer viewpoint C++11 seems to allow things that cause very verbose warnings on Windows

possibly causing Windows developers to ignore all code warnings unless they are fatal (errors)

should be striving to compile clean without warnings on all platforms, but with this setup, Linux devs can (and have) add a plurality of Windows warnings without ever being aware of the issue

My pioneer version (and OS):
git, Winblows

@Web-eWorks
Copy link
Member

All builds use CXX_STANDARD 17 statically as a target-level property regardless of platform. (If you're still unsure, remember that std::string_view and std::variant are C++17 library features.) Linux builds allow the use of CXX extensions where needed, and MSVC has a very different set of default warnings than either GCC or Clang, leading to the warnings you're getting. The proper course of action here would be to disable certain warnings for MSVC, integer size truncation being the most egregious one that I can think of.

@joonicks
Copy link
Contributor Author

the git builder doesnt, check the output: "CXX_STANDARD: 11"

I never thought Id hear "the proper .. action .. would be to disable .. warnings"

the whole of #5260 is to fix integer truncation warnings, not hide them

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