标准库标头 <stdckdint.h> (C++26)

来自cppreference.com
< cpp‎ | header


 
 
标准库头
 

此标头原本在 C 标准库中(<stdckdint.h>)。

此标头是数值库的一部分,特别是,它提供了几个带检查算术的函数模板。

未指定 <stdckdint.h> 是否提供命名空间 std 中的任何声明。

函数

(C++26)
两个整数的带检查加法运算
(函数模板)[编辑]
(C++26)
两个整数的带检查减法运算
(函数模板)[编辑]
(C++26)
两个整数的带检查乘法运算
(函数模板)[编辑]

[编辑]概要

#define __STDC_VERSION_STDCKDINT_H__ 202311L   template<class type1, class type2, class type3>bool ckd_add(type1* result, type2 a, type3 b);   template<class type1, class type2, class type3>bool ckd_sub(type1* result, type2 a, type3 b);   template<class type1, class type2, class type3>bool ckd_mul(type1* result, type2 a, type3 b);
close