|
cxxomfort
rel.20211024
Simple backports for C++ - https://ryan.gulix.cl/fossil.cgi/cxxomfort/
|
Features related to Standard header <cstddef>.
Features included in this section and mapped to global nsmespace or std:::
max_align_t (C++11)std::byte , to_integral() (C++17)Non-backport features (cxxomfort::fix):
to_byte() - obtain a std::byte value for a given integral.to_integer() - obtain the value of a std::byte.to_value() - overload synonym for to_integral(std::byte).Other features:
ssize_t - This signed type is defined for non-POSIX systems, see LWG2251 "ssize_t" .Implementation Macros
std::byte implementation level: CXXOMFORT_IMPLEMENTS_std_byte ssize_t implementation level: CXXOMFORT_IMPLEMENTS_ssize_t C++17's byte can not be directly initialized with integral values in C++14 or previous due to the requirements on conversions to enum class types. The cxxomfort library exposes the following names under cxxomfort::fix in order to work with variables of type std::byte :
POSIX systems expose the ssize_t type which is essentially a signed version of size_t . This type is exposed by cxxomfort when available, otherwise it's calculated from already existing types as basically make_signed<size_t>::type.
ssize_t .The macro CXXOMFORT_IMPLEMENTS_ssize_t informs how this fetaure is provided:
>= CXXO_IMPLSTATUS_NATIVE() - if ssize_t already exists in the system headers (POSIX or otherwise). >= CXXO_IMPLSTATUS_BACKPORT() - if cxxomfort provides it. == 0 - if it can not be added.
1.8.13