Skip to content

apply uppercase flag to compound specifiers #486#488

Merged
BurntSushi merged 1 commit intoBurntSushi:masterfrom
ChrisDryden:fix-strftime-uppercase-compound
Feb 12, 2026
Merged

apply uppercase flag to compound specifiers #486#488
BurntSushi merged 1 commit intoBurntSushi:masterfrom
ChrisDryden:fix-strftime-uppercase-compound

Conversation

@ChrisDryden
Copy link
Copy Markdown
Contributor

@ChrisDryden ChrisDryden commented Jan 14, 2026

This approach for #486 checks the extension flag that is passed into the format_* to change the format string if the uppercase flag was set. This was the main approach that I found could be more easily extended for other compound flags.

The overarching purpose of this fix is to use it in uutils coreutils: uutils/coreutils#10242

Copy link
Copy Markdown
Owner

@BurntSushi BurntSushi 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 not a huge fan of this fix, but I don't see another way to do this without semver incompatible changes. I'm especially not a fan because this doesn't fix the %#c case. But I'll take this in and re-evaluate the API here for Jiff 1.0. I created #513 to track that.

@BurntSushi BurntSushi force-pushed the fix-strftime-uppercase-compound branch from 8b198ed to 8b90983 Compare February 12, 2026 00:41
@BurntSushi BurntSushi force-pushed the fix-strftime-uppercase-compound branch from 8b90983 to 16858c9 Compare February 12, 2026 00:43
@BurntSushi BurntSushi merged commit 0cfd63b into BurntSushi:master Feb 12, 2026
40 checks passed
@BurntSushi
Copy link
Copy Markdown
Owner

This PR is on crates.io in jiff 0.2.20.

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.

2 participants