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

Fix: Silence some warnings when building with clang-cl on VS 2019 #8195

Merged
merged 1 commit into from Jun 18, 2020

Conversation

@nielsmh
Copy link
Contributor

@nielsmh nielsmh commented Jun 6, 2020

Clang-cl presents as both _MSC_VER and __clang__ in the preprocessor which makes some things confusing.

It was somewhat difficult to get it building with clang-cl, in particular making vcpkg behave, and I don't exactly remember what I did. This will need to be documented at some point, as I think I remember testing the clang-cl build to be measurably faster than the Microsoft compiler build.

Clang-cl presents as both _MSC_VER and __clang__ in the preprocessor which makes some things confusing.
@nielsmh nielsmh force-pushed the clang-cl-warnings branch from a29a2ad to a84fcb3 Jun 6, 2020
@@ -198,7 +204,11 @@

#define CDECL _cdecl
#define WARN_FORMAT(string, args)
#define FINAL sealed
# ifndef __clang__
# define FINAL sealed
Copy link
Member

@frosch123 frosch123 Jun 6, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we still need this? "final" is C++11

@LordAro LordAro merged commit 9895ced into OpenTTD:master Jun 18, 2020
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants