Title
Incomplete specification of header <cinttypes>
Status
c++11
Section
[istringstream]
Submitter
Canada

Created on 2010-08-25.00:00:00 last changed 162 months ago

Messages

Date: 2010-11-24.14:01:03

Proposed resolution:

The wording refers to N3126.

  1. Add the following series of new paragraphs following [c.files] p.1:

    Table 132 describes header <cinttypes>. [Note: The macros defined by <cinttypes> are provided unconditionally. In particular, the symbol __STDC_FORMAT_MACROS, mentioned in footnote 182 of the C standard, plays no role in C++. — end note ]

    2 - The contents of header <cinttypes> are the same as the Standard C library header <inttypes.h>, with the following changes:

    3 - The header <cinttypes> includes the header <cstdint> instead of <stdint.h>.

    4 - If and only if the type intmax_t designates an extended integer type ([basic.fundamental]), the following function signatures are added:

    intmax_t abs(intmax_t);
    imaxdiv_t div(intmax_t, intmax_t);
    

    which shall have the same semantics as the function signatures intmax_t imaxabs(intmax_t) and imaxdiv_t imaxdiv(intmax_t, intmax_t), respectively.

Date: 2010-11-24.14:01:03

[ Adopted at 2010-11 Batavia ]

Date: 2010-10-31.20:22:50

[ Post-Rapperswil, Daniel provides wording ]

Subclause [c.files] specifies that <cinttypes> has declarations for abs() and div(); however, the signatures are not present in this subclause. The signatures proposed under TR1 ([tr.c99.inttypes]) are not present in FCD (unless if intmax_t happened to be long long). It is unclear as to which, if any of the abs() and div() functions in [c.math] are meant to be declared by <cinttypes>. This subclause mentions imaxabs() and imaxdiv(). These functions, among other things, are not specified in FCD to be the functions from subclause 7.8 of the C Standard. Finally, <cinttypes> is not specified in FCD to include <cstdint> (whereas <inttypes.h> includes <stdint.h> in C).

Moved to Tentatively Ready with proposed wording after 5 positive votes on c++std-lib.

Date: 2010-10-24.03:04:13

Addresses CA-4

Subclause 27.9.2 [c.files] specifies that <cinttypes> has declarations for abs() and div(); however, the signatures are not present in this subclause. The signatures proposed under TR1 ([tr.c99.inttypes]) are not present in FCD (unless if intmax_t happened to be long long). It is unclear as to which, if any of the abs() and div() functions in [c.math] are meant to be declared by <cinttypes>. This subclause mentions imaxabs() and imaxdiv(). These functions, among other things, are not specified in FCD to be the functions from Subclause 7.8 of the C Standard. Finally, <cinttypes> is not specified in FCD to include <cstdint> (whereas <inttypes.h> includes <stdint.h> in C).

History
Date User Action Args
2011-08-23 20:07:26adminsetstatus: wp -> c++11
2010-11-24 14:01:03adminsetmessages: + msg5437
2010-11-14 13:10:57adminsetstatus: voting -> wp
2010-11-08 14:14:39adminsetstatus: ready -> voting
2010-10-24 03:04:13adminsetmessages: + msg4941
2010-10-21 19:47:27adminsetmessages: + msg4858
2010-08-25 00:00:00admincreate