Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025 #ifndef SU_TYPES_H
00026
00027 #define SU_TYPES_H
00028
00036 #ifndef SU_CONFIG_H
00037 #include <sofia-sip/su_config.h>
00038 #endif
00039
00040 #if SU_HAVE_STDINT
00041 #include <stdint.h>
00042 #elif SU_HAVE_INTTYPES
00043 #include <inttypes.h>
00044 #endif
00045
00046 #if SU_HAVE_SYS_TYPES
00047 #include <sys/types.h>
00048 #endif
00049
00050 #include <stddef.h>
00051
00052 SOFIA_BEGIN_DECLS
00053
00054 #if SU_HAVE_STDINT || SU_HAVE_INTTYPES
00055 #define SU_S64_T int64_t
00056 #define SU_U64_T uint64_t
00057 #define SU_S32_T int32_t
00058 #define SU_U32_T uint32_t
00059 #define SU_S16_T int16_t
00060 #define SU_U16_T uint16_t
00061 #define SU_S8_T int8_t
00062 #define SU_U8_T uint8_t
00063 #define SU_LEAST64_T int_least64_t
00064 #define SU_LEAST32_T int_least32_t
00065 #define SU_LEAST16_T int_least16_t
00066 #define SU_LEAST8_T int_least8_t
00067 #endif
00068
00069 #if DOXYGEN_ONLY || (!SU_HAVE_STDINT && !SU_HAVE_INTTYPES && SU_HAVE_WIN32)
00070
00071
00072
00073 #ifndef _INTPTR_T_DEFINED
00074
00075 typedef SU_INTPTR_T intptr_t;
00076 #endif
00077 #ifndef _UINTPTR_T_DEFINED
00078
00079 typedef unsigned SU_INTPTR_T uintptr_t;
00080 #endif
00081
00083 typedef SU_U64_T uint64_t;
00085 typedef SU_S64_T int64_t;
00087 typedef SU_U32_T uint32_t;
00089 typedef SU_S32_T int32_t;
00091 typedef SU_U16_T uint16_t;
00093 typedef SU_S16_T int16_t;
00095 typedef SU_U8_T uint8_t;
00097 typedef SU_S8_T int8_t;
00098
00100 typedef SU_LEAST64_T int_least64_t;
00102 typedef SU_LEAST32_T int_least32_t;
00104 typedef SU_LEAST16_T int_least16_t;
00106 typedef SU_LEAST8_T int_least8_t;
00107 #endif
00108
00109 #if !SU_HAVE_STDINT && !SU_HAVE_INTTYPES && !SU_HAVE_WIN32
00110 #error "no integer types available."
00111 #endif
00112
00113
00114
00115
00116 #ifdef SOFIA_SSIZE_T
00117
00118 typedef SOFIA_SSIZE_T ssize_t;
00119 #endif
00120
00121 #ifdef SOFIA_ISIZE_T
00122
00131 typedef SOFIA_ISIZE_T isize_t;
00132 #else
00133 typedef size_t isize_t;
00134 #endif
00135
00136 #ifdef SOFIA_ISSIZE_T
00137
00145 typedef SOFIA_ISSIZE_T issize_t;
00146 #else
00147 typedef ssize_t issize_t;
00148 #endif
00149
00150 #ifdef SOFIA_USIZE_T
00151
00159 typedef SOFIA_USIZE_T usize_t;
00160 #else
00161 typedef size_t usize_t;
00162 #endif
00163
00164 SOFIA_END_DECLS
00165
00166 #endif