libacfutils
A general purpose library of utility functions designed to make it easier to develop addons for the X-Plane flight simulator.
Loading...
Searching...
No Matches
types.h
1/*
2 * CDDL HEADER START
3 *
4 * This file and its contents are supplied under the terms of the
5 * Common Development and Distribution License ("CDDL"), version 1.0.
6 * You may only use this file in accordance with the terms of version
7 * 1.0 of the CDDL.
8 *
9 * A full copy of the text of the CDDL should have accompanied this
10 * source. A copy of the CDDL is also available via the Internet at
11 * http://www.illumos.org/license/CDDL.
12 *
13 * CDDL HEADER END
14 */
15/*
16 * Copyright 2017 Saso Kiselkov. All rights reserved.
17 */
18
19#ifndef _ACF_UTILS_TYPES_H_
20#define _ACF_UTILS_TYPES_H_
21
22#include <stdint.h>
23#include <stdlib.h>
24#include <limits.h>
25
26#include "core.h"
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32typedef unsigned int bool_t;
33
34#ifndef B_TRUE
35#define B_TRUE 1
36#define B_FALSE 0
37#endif
38
39#ifdef _MSC_VER
40
41#include <basetsd.h>
42
43#ifndef ssize_t
44#define ssize_t SSIZE_T
45#endif
46
47#ifndef restrict
48#define restrict
49#endif
50
51#elif defined(__cplusplus)
52
53/* C++ doesn't understand restrict */
54#ifndef restrict
55#define restrict
56#endif
57
58#endif /* (_MSC_VER) */
59
60#ifdef __cplusplus
61}
62#endif
63
64#endif /* _ACF_UTILS_TYPES_H_ */