stdint.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. #ifndef __STDINT_H
  2. #define __STDINT_H
  3. #include "limits.h"
  4. typedef signed char int8_t;
  5. typedef signed short int16_t;
  6. typedef signed int int32_t;
  7. typedef signed long long int64_t;
  8. typedef unsigned char uint8_t;
  9. typedef unsigned short uint16_t;
  10. typedef unsigned int uint32_t;
  11. typedef unsigned long long uint64_t;
  12. typedef signed char int_fast8_t;
  13. typedef signed short int_fast16_t;
  14. typedef signed int int_fast32_t;
  15. typedef signed long long int_fast64_t;
  16. typedef unsigned char uint_fast8_t;
  17. typedef unsigned short uint_fast16_t;
  18. typedef unsigned int uint_fast32_t;
  19. typedef unsigned long long uint_fast64_t;
  20. typedef signed char int_least8_t;
  21. typedef signed short int_least16_t;
  22. typedef signed int int_least32_t;
  23. typedef signed long long int_least64_t;
  24. typedef unsigned char uint_least8_t;
  25. typedef unsigned short uint_least16_t;
  26. typedef unsigned int uint_least32_t;
  27. typedef unsigned long long uint_least64_t;
  28. typedef int32_t intptr_t;
  29. typedef uint32_t uintptr_t;
  30. typedef int64_t intmax_t;
  31. typedef uint64_t uintmax_t;
  32. #define INT8_C(x) x
  33. #define INT16_C(x) x
  34. #define INT32_C(x) x
  35. #define INT64_C(x) x ## L
  36. #define UINT8_C(x) x
  37. #define UINT16_C(x) x
  38. #define UINT32_C(x) x ## U
  39. #define UINT64_C(x) x ## UL
  40. #define INTMAX_C(x) x ## L
  41. #define UINTMAX_C(x) x ## UL
  42. #define PTRDIFF_MIN INT_MIN
  43. #define PTRDIFF_MAX INT_MAX
  44. #define SIZE_MAX UINT_MAX
  45. #endif