/simpletypesystem/trunk

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/simpletypesystem/trunk
5.2.7 by Gustav Hartvigsson
* Switched licence to a more permisive one.
1
/*
2
*/
3
4
#ifndef __H_DEFS__
5
#define __H_DEFS__
6
23 by Gustav Hartvigsson
* Fixed some of the build warnings.
7
#include <limits.h>
8
5.2.7 by Gustav Hartvigsson
* Switched licence to a more permisive one.
9
/** @file
10
 * 
11
 */
12
13
#ifdef __cplusplus
14
#define BEGIN_DECLS extern "C" {
15
#else
16
#define BEGIN_DECLS
17
#endif /*__cplusplus*/
18
19
20
#ifdef __cplusplus
21
#define END_DECLS }
22
#else
23
#define END_DECLS
24
#endif /* __cplusplus */
25
26 by Gustav Hartvigsson
* Added something to config.h.in, still not sure how it cmake works.
26
BEGIN_DECLS
27
23 by Gustav Hartvigsson
* Fixed some of the build warnings.
28
#ifndef FALSE
29
#define FALSE 0
30
#endif
31
32
#ifndef TRUE
33
#define TRUE !FALSE
34
#endif
35
36
typedef long hash_t;
37
38
typedef void* spointer;
39
40
typedef enum {
41
  S_TYPES_NONE = 0,
42
  S_TYPES_INT,
43
  S_TYPES_CHAR,
44
  S_TYPES_SHORT,
45
  S_TYPES_BOOLEAN,
46
  S_TYPES_LONG,
47
  S_TYPES_UINT,
48
  
49
  
50
  S_TYPES_OBJECT = INT_MAX - 1,
51
  S_TYPES_INVALID = INT_MAX
52
} S_TYPES;
5.2.7 by Gustav Hartvigsson
* Switched licence to a more permisive one.
53
26 by Gustav Hartvigsson
* Added something to config.h.in, still not sure how it cmake works.
54
55
/* Colour definitions for console prints */
56
#define RESET   "\033[0m"
57
#define BLACK   "\033[30m"      /* Black */
58
#define RED     "\033[31m"      /* Red */
59
#define GREEN   "\033[32m"      /* Green */
60
#define YELLOW  "\033[33m"      /* Yellow */
61
#define BLUE    "\033[34m"      /* Blue */
62
#define MAGENTA "\033[35m"      /* Magenta */
63
#define CYAN    "\033[36m"      /* Cyan */
64
#define WHITE   "\033[37m"      /* White */
65
#define BOLDBLACK   "\033[1m\033[30m"      /* Bold Black */
66
#define BOLDRED     "\033[1m\033[31m"      /* Bold Red */
67
#define BOLDGREEN   "\033[1m\033[32m"      /* Bold Green */
68
#define BOLDYELLOW  "\033[1m\033[33m"      /* Bold Yellow */
69
#define BOLDBLUE    "\033[1m\033[34m"      /* Bold Blue */
70
#define BOLDMAGENTA "\033[1m\033[35m"      /* Bold Magenta */
71
#define BOLDCYAN    "\033[1m\033[36m"      /* Bold Cyan */
72
#define BOLDWHITE   "\033[1m\033[37m"      /* Bold White */
73
74
END_DECLS
75
5.2.7 by Gustav Hartvigsson
* Switched licence to a more permisive one.
76
#endif