N2337

Nick Stoughton

Proposal To Add Extended Month Name Formats to strftime()

Background

Some Slavic languages, for example Russian and Polish, use the nominative case for a month/year combination, and the genitive case for a day/month/year combination. The strftime() function does not support grammatically correct forms with the current definition.

For example, in Russian the name of the fifth month is май, which is only three letters, so it doesn't change when abbreviated, and the abbreviation declines just like the full noun (май nominative, мая genitive).

This issue was brought to the Austin Group for consideration in the next POSIX standard, and the group has accepted this addition. However, we believe that this should also be reflected in a future version of the C standard. See also http://austingroupbugs.net/view.php?id=258and http://austingroupbugs.net/view.php?id=1166 for further details.

Proposed Additions to C2x

To match the requirements that will be included in the next edition of ISO/IEC Standard 9945, the following should be added to 7.27.3.5 para 4 (using N2310), in the appropriate alphabetic location:

%Ob        is replaced by the locale’s alternative appropriate full month name.

%OB        is replaced by the locale’s abbreviated alternative month name.