fix: add French day ordinal suffix in format_o#60
Draft
Koan-Bot wants to merge 1 commit intoatoomic:mainfrom
Draft
fix: add French day ordinal suffix in format_o#60Koan-Bot wants to merge 1 commit intoatoomic:mainfrom
Koan-Bot wants to merge 1 commit intoatoomic:mainfrom
Conversation
French format_o was returning bare day numbers while all other language modules include ordinal suffixes. Fixed format_o to use @Dsuf and corrected @Dsuf array indexing (was off-by-one: index 0 should be unused placeholder since days are 1-31). Results: "1er", "2e", "3e", ..., "31e" — following French convention. Closes atoomic#22 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What
Fix
format_oinDate::Language::Frenchto return ordinal day numbers with French suffixes ("1er", "2e", etc.) instead of bare numbers.Why
French was the only language module where
format_oreturned just the day number — all others include language-appropriate suffixes. Originally reported as rt.cpan.org#128396 (issue #22) and previously attempted in PR #54, which went stale due to encoding issues from being based on pre-modernization code.How
@Dsufoff-by-one: array was indexed starting at 0 with "er", butformat_oindexes by day number (1-31). Index 0 is now an unused placeholder, index 1 = "er" (premier), indices 2-31 = "e".format_ofrom$_[0]->[3]tosprintf("%2d%s",$_[0]->[3],$Dsuf[$_[0]->[3]])— same pattern used by German, Dutch, Swedish, and other language modules.Testing
t/format.tcovering all format specifiersCloses #22
Supersedes #54
🤖 Generated with Claude Code
Quality Report
Changes: 2 files changed, 46 insertions(+), 3 deletions(-)
Code scan: clean
Tests: skipped
Branch hygiene: clean
Generated by Kōan post-mission quality pipeline