summaryrefslogtreecommitdiff
path: root/Debugger/types.h
blob: 3a1d4cb3416ee7d26d5a5f112c18d7bbdf72ff1b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/** @file types.h
 *  @brief Basic type definitions for the Arm7 platform.
 */

/* Copyright (c) 2007,2008 the NxOS developers
 *
 * See AUTHORS for a full list of the developers.
 *
 * Redistribution of this file is permitted under
 * the terms of the GNU Public License (GPL) version 2.
 */

#ifndef __NXOS_BASE_TYPES_H__
#define __NXOS_BASE_TYPES_H__

/** @addtogroup typesAndUtils */
/*@{*/

typedef unsigned char U8; /**< Unsigned 8-bit integer. */
typedef signed char S8; /**< Signed 8-bit integer. */
typedef unsigned short U16; /**< Unsigned 16-bit integer. */
typedef signed short S16; /**< Signed 16-bit integer. */
typedef unsigned long U32; /**< Unsigned 32-bit integer. */
typedef signed long S32; /**< Signed 32-bit integer. */

#ifndef __SIZE_TYPE__
#define __SIZE_TYPE__ U32 /**< Used to go conform with gcc, otherwise we are
                            risking an error because of conflicting types for size_t */
#endif
typedef __SIZE_TYPE__ size_t; /**< Abstract size type, needed by the memory allocator. */

typedef U8 bool; /**< Boolean data type. */
#define FALSE (0) /**< False boolean value. */
#define TRUE (!FALSE) /**< True boolean value. */

#ifndef NULL
/** Definition of the NULL pointer. */
#define NULL ((void*)0)
#endif

/** A function that takes no arguments and returns nothing. */
typedef void (*nx_closure_t)(void);

/*@}*/

#endif