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
build: Disable -Wbraced-scalar-init, which is incompatible with -Wc++11-narrowing #23191
Conversation
Concept ACK |
Why is it incompatible? In the output above there is 1 error due to OTOH, |
Is the intention to use |
|
It is currently not possible to compile Bitcoin Core with either of those settings. |
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, this pull request conflicts with the following ones:
If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first. |
🐙 This pull request conflicts with the target branch and needs rebase. Want to unsubscribe from rebase notifications on this pull request? Just convert this pull request to a "draft". |
@@ -475,6 +475,8 @@ if test "x$CXXFLAGS_overridden" = "xno"; then | |||
AX_CHECK_COMPILE_FLAG([-Wunused-parameter],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-unused-parameter"],,[[$CXXFLAG_WERROR]]) | |||
AX_CHECK_COMPILE_FLAG([-Wself-assign],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-self-assign"],,[[$CXXFLAG_WERROR]]) | |||
AX_CHECK_COMPILE_FLAG([-Wunused-local-typedef],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-unused-local-typedef"],,[[$CXXFLAG_WERROR]]) | |||
dnl -Wbraced-scalar-init is incompatible with -Wc++11-narrowing | |||
AX_CHECK_COMPILE_FLAG([-Wbraced-scalar-init],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-braced-scalar-init"],,[[$CXXFLAG_WERROR]]) |
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.
AX_CHECK_COMPILE_FLAG([-Wbraced-scalar-init],[NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-braced-scalar-init"],,[[$CXXFLAG_WERROR]]) | |
AX_CHECK_COMPILE_FLAG([-Wbraced-scalar-init], [NOWARN_CXXFLAGS="$NOWARN_CXXFLAGS -Wno-braced-scalar-init"], [], [$CXXFLAG_WERROR]) |
To test:
Before:
After: