NSDateComponentsFormatter produces wrong short format for minutes with the fr_FR locale
| Originator: | guillaume.algis | ||
| Number: | rdar://25221084 | Date Originated: | 17-Mar-2016 07:23 PM |
| Status: | Open | Resolved: | |
| Product: | OS X | Product Version: | Mac OS X 10.11.3 (15D21) |
| Classification: | Other Bug | Reproducible: | Always |
Summary: When using the French (fr_FR) locale, NSDateComponentsFormatter with its unitsStyle set to NSDateComponentsFormatterUnitsStyleShort produces an output with minutes abbreviated "mn" instead of the legal "min". Steps to Reproduce: Output any time interval greater than 60 seconds with NSDateComponentsFormatter with the locale set to fr_FR, and unitsStyle set to NSDateComponentsFormatterUnitsStyleShort. Expected Results: The minutes are abbreviated as "min". Actual Results: The minutes are abbreviated as "mn". Regression: Always occur on OS X 10.11.3 and iOS 9.2.1. Notes: Here's a link to the Journal Officiel describing the authorized units abbreviations [fr] : https://www.legifrance.gouv.fr/jo_pdf.do?numJO=0&dateJO=19751223&pageDebut=13216&pageFin=&pageCourante=13222 Relevant excerpt (translation is my own) : > Denomination : minute ; Symbol : min ; Observations: For the minute, the m symbol can be used when there can be no ambiguity, such as when the time expressed includes not only minutes but hours or seconds Wikipedia article on the minute unit [fr] : https://fr.wikipedia.org/wiki/Minute_(temps) Attached is a minimal Swift 2 (Xcode 7.2.1) Playground demonstrating the issue. Output is expected to be "6 min et 40 s" but is "6 mn et 40 s".
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!
Radar closed as "Duplicate of 21332711 (Closed)"