20 General utilities library [utilities]

20.12 Time utilities [time]

20.12.8 Date and time functions [date.time]

Table [tab:util.hdr.ctime] describes the header <ctime>.

Table 60 — Header <ctime> synopsis
Types: size_t clock_t time_t
Struct: tm
asctime clock difftime localtime strftime
ctime gmtime mktime time

The contents are the same as the Standard C library header <time.h>.232 The functions asctime, ctime, gmtime, and localtime are not required to avoid data races ([res.on.data.races]).

See also: ISO C Clause 7.12, Amendment 1 Clause 4.6.4.

strftime supports the C conversion specifiers C, D, e, F, g, G, h, r, R, t, T, u, V, and z, and the modifiers E and O.