-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
Fixed GCC version test. #771
Closed
Closed
Changes from 3 commits
Commits
Show all changes
6 commits
Select commit
Hold shift + click to select a range
120a969
Added quotes for strings in ranges and tuple likes.
Remotion 85fc14a
Fixed line length.
Remotion 8d0e261
Fixed GCC version test.
Remotion 5b2b804
Added support for rgb color output.
Remotion 210e0a4
Using enum class now.
Remotion d102cfd
Document that file should be in wide-oriented mode for wide print
vitaut File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
I think you could use
FMT_GCC_VERSION
instead of__GNUC__ * 100 + __GNUC_MINOR__
(possibly after reordering defines).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.
FMT_GCC_VERSION
is defined in core.h, which is included after this. This also needs to be before the inclusion of core.h to disable warnings from that header. On your first review in #736 you said thatFMT_GCC_VERSION
needs to be in core.h.So that leaves two options that I can think of:
FMT_GCC_VERSION
, like this: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.
I said that very incoherently. What I was trying to say was that the warnings need to be disabled before the inclusion of core.h, but
FMT_GCC_VERSION
is defined in core.h. So we can either not useFMT_GCC_VERSION
in disabling the warnings or disable them in both headers. The latter would probably be preferable, because now the warnings aren't disabled at all if you only include core.h.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.
I think we can live without disabling these warnings in
fmt/core.h
for now, so I suggest just movingfmt/core.h
to the front and usingFMT_GCC_VERSION
here.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.
The original point of this PR was to fix the version check so there wouldn't be any -Wshadow warnings.
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.
Yes and this will fix the reported warnings in
fmt/format.h
(but not infmt/core.h
which is OK since no such warnings were reported).