comparison th_types.h @ 81:69aed051f84d

Synced th-libs.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 20 Apr 2009 22:02:37 +0300
parents 728243125263
children 7eaf065f7a65
comparison
equal deleted inserted replaced
80:335b5a74c22e 81:69aed051f84d
34 34
35 /* Default assumptions for these types should be ok for most 32bit platforms... 35 /* Default assumptions for these types should be ok for most 32bit platforms...
36 * feel free to define TH_TYPE_* if necessary to remedy 36 * feel free to define TH_TYPE_* if necessary to remedy
37 */ 37 */
38 #ifdef TH_TYPE_I8 38 #ifdef TH_TYPE_I8
39 typedef unsigned TH_TYPE_I8 uint8_t; /* 8 bits, unsigned */ 39 typedef unsigned TH_TYPE_I8 uint8_t; /* 8 bits, unsigned */
40 typedef signed TH_TYPE_I8 int8_t; /* 8 bits, signed */ 40 typedef signed TH_TYPE_I8 int8_t; /* 8 bits, signed */
41 #else 41 #else
42 #ifndef HAVE_INT_TYPES 42 #ifndef HAVE_INT_TYPES
43 typedef unsigned char uint8_t; 43 typedef unsigned char uint8_t;
44 typedef signed char int8_t; 44 typedef signed char int8_t;
45 #endif 45 #endif
46 #endif 46 #endif
47 47
48 48
49 #ifdef TH_TYPE_I16 49 #ifdef TH_TYPE_I16
50 typedef unsigned TH_TYPE_I16 uint16_t; /* 16 bits, unsigned == 2 BYTEs */ 50 typedef unsigned TH_TYPE_I16 uint16_t; /* 16 bits, unsigned == 2 BYTEs */
51 typedef signed TH_TYPE_I16 int16_t; /* 16 bits, signed */ 51 typedef signed TH_TYPE_I16 int16_t; /* 16 bits, signed */
52 #else 52 #else
53 #ifndef HAVE_INT_TYPES 53 #ifndef HAVE_INT_TYPES
54 typedef unsigned short int uint16_t; 54 typedef unsigned short int uint16_t;
55 typedef signed short int int16_t; 55 typedef signed short int int16_t;
56 #endif 56 #endif
57 #endif 57 #endif
58 58
59 #ifdef TH_TYPE_I32 59 #ifdef TH_TYPE_I32
60 typedef unsigned TH_TYPE_I32 uint32_t; /* 32 bits, unsigned == 4 BYTES == 2 WORDs */ 60 typedef unsigned TH_TYPE_I32 uint32_t; /* 32 bits, unsigned == 4 BYTES == 2 WORDs */
61 typedef signed TH_TYPE_I32 int32_t; /* 32 bits, signed */ 61 typedef signed TH_TYPE_I32 int32_t; /* 32 bits, signed */
62 #else 62 #else
63 #ifndef HAVE_INT_TYPES 63 #ifndef HAVE_INT_TYPES
64 typedef unsigned int uint32_t; 64 typedef unsigned int uint32_t;
65 typedef signed int int32_t; 65 typedef signed int int32_t;
66 #endif 66 #endif
67 #endif 67 #endif
68 68
69 #ifdef TH_TYPE_I64 69 #ifdef TH_TYPE_I64
70 typedef unsigned TH_TYPE_I64 uint64_t; /* 64 bits, unsigned == 8 BYTES == 2 DWORDs */ 70 typedef unsigned TH_TYPE_I64 uint64_t; /* 64 bits, unsigned == 8 BYTES == 2 DWORDs */
71 typedef signed TH_TYPE_I64 int64_t; /* 64 bits, signed */ 71 typedef signed TH_TYPE_I64 int64_t; /* 64 bits, signed */
72 #else 72 #else
73 #ifndef HAVE_INT_TYPES 73 #ifndef HAVE_INT_TYPES
74 typedef unsigned long long uint64_t; 74 typedef unsigned long long uint64_t;
75 typedef signed long long int64_t; 75 typedef signed long long int64_t;
76 #endif 76 #endif