strftime %c and additional struct tm membersAuthors: Jay Ghiron
Date: 2026-09-17
Submitted against: C2Y (N3886 draft)
Status: Open
The proposal
N3272
added wording so that %z and %Z in strftime can use additional
members in struct tm added by an implementation. However, %c and
%Ec on some implementations also use these members to determine the
time zone. For example: glibc with en_US.UTF-8 as seen on
godbolt. The same wording should
be copied to %c and %Ec to allow for additional members added by
an implementation to be used.
Modify N3886 7.31.3.6 (The strftime function) paragraph 3:
%cis replaced by the locale’s appropriate date and time representation. Behavior is implementation-defined if the broken-down time structure does not have a value that could be returned bylocaltimeorgmtime. [allspecified in 7.31.1members, including any non-standard additional members]