-
Notifications
You must be signed in to change notification settings - Fork 4.9k
[release/3.1] Fix corefx to build on clang 10 #42900
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM with suggestions
Should I make these suggestions in |
Is this just fixing warnings? For servicing, we should disable the warnings instead of touching the code. |
cc @danmosemsft |
If we can dial this back to disabling warnings, I am happy to seek approval to merge it. |
These suggestions were provided by @lpereira on dotnet/corefx#42900
4d59310
to
827913e
Compare
These suggestions were provided by @lpereira on dotnet/corefx#42900
Clang 10 adds/enables new warnings, some of which is affecting the corefx code. Disable them. This is a "backport" of dotnet/runtime#33734 to corefx. After this commit, I can build all of corefx with Clang 10.
@danmosemsft This is dialed back to disabling warnings now. Could you please get it approved? |
Yup - @omajid can you share why you're working to enable build with clang 10 ? Does RedHat plans to build its 3.1 servicing releases using clang 10? |
I am not aware of any concrete plans for RHEL.
My main motivation is to build .NET Core in Fedora (>= 32) where clang is at version 10. We are currently carrying a local patch for that: https://src.fedoraproject.org/fork/crummel/rpms/dotnet3.1/blob/master/f/corefx-42900-clang-10.patch. I prefer to avoid carrying these patches out of band where possible. |
@Anipik will merge when branch open |
Clang 10 adds/enables new warnings, some of which is affecting the corefx code.
Clang 10 has added
-Walloca
to warn about uses ofalloca()
. Clang 10 has also added-Wimplicit-int-float-conversion
. This commit disables those warnings where applicable.This is a backport of dotnet/runtime#33734 to corefx.
After this commit, I can build all of corefx with Clang 10.