Divergence between std and fmt on ranges formatting
Maintainers usually reply within 9 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Newbie friendliness
- 63/100
Research direction
Run the provided C++ example and compare fmt::println with std::println for the repeated-character view. Read the range-formatting implementation and its existing tests to locate how {:s} handles this range. Done means a regression test confirms fmt matches the standard library's unquoted output.
Written by the indexing model from the issue text.
Description
fmt emits surrouding quotes on {:s}, while std doesn't
#include <fmt/format.h>
#include <fmt/ranges.h>
#include <fmt/std.h>
#include <print>
#include <algorithm>
#include <ranges>
int main() {
std::println("...{:s}...", std::views::repeat('x', 4)); // prints ...xxxx...
fmt::println("...{:s}...", std::views::repeat('x', 4)); // prints ..."xxxx"...
}
- Dominant language
- C++
- Stars
- 25.9k
- Forks
- 3.1k
- Avg merge
- 9d 5h
- Merged PRs (30d)
- 13
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from fmtlib/fmt
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
Maintainers usually reply within 9 days
-
Difficulty 4/5 3-5 days Newbie friendliness 48/100
fmtlib/fmt#5006 · 3 comments ·
Maintainers usually reply within 9 days
-
<stdfloat>May be free again @shreyas-s1403 claimed this 13 days ago, and no pull request is open. Open
Difficulty 4/5 3-5 days Newbie friendliness 45/100
fmtlib/fmt#4725 · 10 comments · 1 reaction ·
Maintainers usually reply within 9 days
-
Difficulty 5/5 Over a week Newbie friendliness 35/100
fmtlib/fmt#4518 · 1 comment · 6 reactions ·
Maintainers usually reply within 9 days
-
failed to print error code `:s` fail on windows due to encoding errorMay be free again @shreyas-s1403 claimed this 13 days ago, and no pull request is open. Open
Difficulty 4/5 3-5 days Newbie friendliness 35/100
fmtlib/fmt#4436 · 11 comments ·
Maintainers usually reply within 9 days
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
NVIDIA-RTX/NRI#312 ·
Maintainers usually reply within 1 day
-
permute_q_b_proj / permute_wv_proj accept scale factors from another devicePossibly taken @0z5a claimed this today. Open
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
deepseek-ai/FlashMLA#247 ·
Maintainers usually reply within 1 day
-
Linux npm packaging leaves workspace files that block subsequent CI checkoutPossibly taken @Spockkk0225 claimed this today. Openci
Difficulty 2/5 1-3 hours Newbie friendliness 73/100
alibaba/neug#1195 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 3 days