-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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 compilation errors due to make_format_args
in gcc 14.1.1 with c++20
#4042
Merged
Merged
Changes from 2 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
bd87e0f
use fmt::make_format_args in make_print_args
toge 4a2621d
add test condition
toge 66aaa2e
fix configure error on older gcc
toge 34e5eaa
remove gradle files
toge 0949bbc
revert unnecessary codes
toge 027e6f0
revert forcing cxx_std_20 codes
toge dc88147
revert deleting likne
toge 71f9d27
improve conditions
toge 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
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file added
BIN
+17 Bytes
support/.gradle/8.1.1/dependencies-accessors/dependencies-accessors.lock
Binary file not shown.
Empty file.
Binary file not shown.
Binary file not shown.
Empty file.
Binary file not shown.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
#Tue Jul 02 00:25:24 JST 2024 | ||
gradle.version=8.1.1 |
Empty file.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,10 @@ | |
// For the license information refer to format.h. | ||
|
||
#include "fmt/printf.h" | ||
// include <format> if possible for https://github.com/fmtlib/fmt/pull/4042 | ||
#if defined(__has_include) && __has_include(<format>) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. #if FMT_HAS_INCLUDE(<format>) && FMT_CPLUSPLUS > 201703L There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @phprus |
||
# include <format> | ||
#endif | ||
|
||
#include <cctype> | ||
#include <climits> | ||
|
@@ -554,6 +558,8 @@ TEST(printf_test, fixed_large_exponent) { | |
} | ||
|
||
TEST(printf_test, make_printf_args) { | ||
const std::string thing("World"); | ||
fmt::printf("PRINTF: Hello, %s!\n", thing); | ||
int n = 42; | ||
EXPECT_EQ("[42] something happened", | ||
fmt::vsprintf(fmt::string_view("[%d] %s happened"), | ||
|
Oops, something went wrong.
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.
This standard should be controlled externally, not here. Let's revert.
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.
@vitaut
Sorry I try to revert both cxx_std and .gradle files.
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.
@vitaut
Now I finished.
Cloud you review it again?