Chameleon

Chameleon Svn Source Tree

Root/branches/xZenu/src/include/arm/_types.h

Source at commit 1270 created 12 years 8 months ago.
By meklort, Add arm headers. update makefiles
1/*
2 * Copyright (c) 2000-2007 Apple Inc. All rights reserved.
3 */
4#ifndef_BSD_ARM__TYPES_H_
5#define_BSD_ARM__TYPES_H_
6
7/*
8 * This header file contains integer types. It's intended to also contain
9 * flotaing point and other arithmetic types, as needed, later.
10 */
11
12#ifdef __GNUC__
13typedef __signed char__int8_t;
14#else/* !__GNUC__ */
15typedef char__int8_t;
16#endif/* !__GNUC__ */
17typedef unsigned char__uint8_t;
18typedefshort__int16_t;
19typedefunsigned short__uint16_t;
20typedef int__int32_t;
21typedef unsigned int__uint32_t;
22typedef long long__int64_t;
23typedef unsigned long long__uint64_t;
24
25typedef long__darwin_intptr_t;
26typedef unsigned int__darwin_natural_t;
27
28/*
29 * The rune type below is declared to be an ``int'' instead of the more natural
30 * ``unsigned long'' or ``long''. Two things are happening here. It is not
31 * unsigned so that EOF (-1) can be naturally assigned to it and used. Also,
32 * it looks like 10646 will be a 31 bit standard. This means that if your
33 * ints cannot hold 32 bits, you will be in trouble. The reason an int was
34 * chosen over a long is that the is*() and to*() routines take ints (says
35 * ANSI C), but they use __darwin_ct_rune_t instead of int. By changing it
36 * here, you lose a bit of ANSI conformance, but your programs will still
37 * work.
38 *
39 * NOTE: rune_t is not covered by ANSI nor other standards, and should not
40 * be instantiated outside of lib/libc/locale. Use wchar_t. wchar_t and
41 * rune_t must be the same type. Also wint_t must be no narrower than
42 * wchar_t, and should also be able to hold all members of the largest
43 * character set plus one extra value (WEOF). wint_t must be at least 16 bits.
44 */
45
46typedef int__darwin_ct_rune_t;/* ct_rune_t */
47
48/*
49 * mbstate_t is an opaque object to keep conversion state, during multibyte
50 * stream conversions. The content must not be referenced by user programs.
51 */
52typedef union {
53char__mbstate8[128];
54long long_mbstateL;/* for alignment */
55} __mbstate_t;
56
57typedef __mbstate_t__darwin_mbstate_t;/* mbstate_t */
58
59#if defined(__GNUC__) && defined(__PTRDIFF_TYPE__)
60typedef __PTRDIFF_TYPE____darwin_ptrdiff_t;/* ptr1 - ptr2 */
61#else
62typedef int__darwin_ptrdiff_t;/* ptr1 - ptr2 */
63#endif /* __GNUC__ */
64
65#if defined(__GNUC__) && defined(__SIZE_TYPE__)
66typedef __SIZE_TYPE____darwin_size_t;/* sizeof() */
67#else
68typedef unsigned long__darwin_size_t;/* sizeof() */
69#endif
70
71#if (__GNUC__ > 2)
72typedef __builtin_va_list__darwin_va_list;/* va_list */
73#else
74typedef void *__darwin_va_list;/* va_list */
75#endif
76
77#if defined(__GNUC__) && defined(__WCHAR_TYPE__)
78typedef __WCHAR_TYPE____darwin_wchar_t;/* wchar_t */
79#else
80typedef __darwin_ct_rune_t__darwin_wchar_t;/* wchar_t */
81#endif
82
83typedef __darwin_wchar_t__darwin_rune_t;/* rune_t */
84
85#if defined(__GNUC__) && defined(__WINT_TYPE__)
86typedef __WINT_TYPE____darwin_wint_t;/* wint_t */
87#else
88typedef __darwin_ct_rune_t__darwin_wint_t;/* wint_t */
89#endif
90
91typedef unsigned long__darwin_clock_t;/* clock() */
92typedef __uint32_t__darwin_socklen_t;/* socklen_t (duh) */
93typedef long__darwin_ssize_t;/* byte count or error */
94typedef long__darwin_time_t;/* time() */
95
96#endif/* _BSD_ARM__TYPES_H_ */
97

Archive Download this file

Revision: 1270