Skip to content
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

Use Formatter::pad (instead of write_str) for Weekdays #1621

Merged
merged 1 commit into from
Oct 14, 2024

Conversation

horazont
Copy link
Contributor

That way, width, alignment and fill from the format string are respected.

Fixes #1620.

If your feature is semver-compatible, please target the main branch;
for semver-incompatible changes, please target the 0.5.x branch.

Excellent question whether this is semver-compatible. I'm not 100% sure: On the one hand, this changes behaviour others may be relying on. On the other hand, it is fixing something which may be perceived as a bug. I'll let the reviewer judge and will retarget accordingly.

That way, width, alignment and fill from the format string are
respected.

Fixes chronotope#1620.
Copy link
Member

@djc djc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm definitely counting this as semver-compatible. Thanks!

Copy link

codecov bot commented Oct 14, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 91.12%. Comparing base (d8a177e) to head (5fbd077).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1621   +/-   ##
=======================================
  Coverage   91.12%   91.12%           
=======================================
  Files          37       37           
  Lines       17129    17137    +8     
=======================================
+ Hits        15608    15616    +8     
  Misses       1521     1521           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@djc djc merged commit 771c047 into chronotope:main Oct 14, 2024
35 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

std::fmt::Display implementation of Weekday does not honour width, alignment or fill
2 participants