我想在我的C代码中使用64位整数.我知道我可以#include< cstdint>然后声明一个uint64_t或使用unsigned long long(或等效的signed signed).
解决方法
uint64_t是:
Optional: These typedefs are not defined if no types with such
characteristics exist.@H_301_3@
从Should I use long long or int64_t for portable code?开始:@H_301_3@
The types
long long
andunsigned long long
are standard C and standard C++ types each with at least 64 bits. All compilers I’m aware of provide these types,except possibly when in a-pedantic
mode but in this caseint64_t
oruint64_t
won’t be available with pre-C++ 2011 compilers,either. “@H_301_3@
g / clang支持long long / int64_t的日期是什么?@H_301_3@
Since 07002 (aka 07003).@H_301_3@
正如DavidÁlvarez所说.@H_301_3@