stdint.h 873 B

1234567891011121314151617181920212223242526272829303132333435
  1. #ifndef __STDINT_H__
  2. #define __STDINT_H__
  3. #include <rtthread.h>
  4. typedef rt_int8_t int8_t;
  5. typedef rt_uint8_t uint8_t;
  6. typedef rt_int16_t int16_t;
  7. typedef rt_uint16_t uint16_t;
  8. typedef rt_int32_t int32_t;
  9. typedef rt_uint32_t uint32_t;
  10. typedef long long int64_t;
  11. typedef unsigned long long uint64_t;
  12. /*
  13. * 7.18.2 Limits of specified-width integer types.
  14. *
  15. * The following object-like macros specify the minimum and maximum limits
  16. * of integer types corresponding to the typedef names defined above.
  17. */
  18. /* 7.18.2.1 Limits of exact-width integer types */
  19. #define INT8_MIN (-0x7f - 1)
  20. #define INT16_MIN (-0x7fff - 1)
  21. #define INT32_MIN (-0x7fffffff - 1)
  22. #define INT8_MAX 0x7f
  23. #define INT16_MAX 0x7fff
  24. #define INT32_MAX 0x7fffffff
  25. #define UINT8_MAX 0xff
  26. #define UINT16_MAX 0xffff
  27. #define UINT32_MAX 0xffffffffU
  28. #endif