summaryrefslogtreecommitdiff
path: root/ace/os_include/os_stddef.h
blob: 117a332b6f2ab4f61d66f2e054a5311d0742972e (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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
// -*- C++ -*-

//=============================================================================
/**
 *  @file    os_stddef.h
 *
 *  standard type definitions
 *
 *  $Id$
 *
 *  @author Don Hinton <dhinton@dresystems.com>
 *  @author This code was originally in various places including ace/OS.h.
 */
//=============================================================================

// From http://www.UNIX-systems.org/single_unix_specification/

#ifndef ACE_OS_INCLUDE_OS_STDDEF_H
#define ACE_OS_INCLUDE_OS_STDDEF_H

#include /**/ "ace/pre.h"

#include "ace/config-lite.h"

#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */

#if !defined (ACE_LACKS_STDDEF_H)
#  include /**/ <stddef.h>
#endif /* !ACE_LACKS_STDDEF_H */

// Place all additions (especially function declarations) within extern "C" {}
#ifdef __cplusplus
extern "C"
{
#endif /* __cplusplus */

//  Signed integer type of the result of subtracting two pointers.
#if defined (ACE_LACKS_PTRDIFF_T)
#  if !defined (ACE_PTRDIFF_T_TYPE)
#    define ACE_PTRDIFF_T_TYPE unsigned long
#  endif /* !ACE_PTRDIFF_T_TYPE */
   typedef ACE_PTRDIFF_T_TYPE ptrdiff_t;
#endif /* ACE_LACKS_PTRDIFF_T */

/*
  Integer type whose range of values can represent distinct wide-character
  codes for all members of the largest character set specified among the
  locales supported by the compilation environment: the null character has
  the code value 0 and each member of the portable character set has a code
  value equal to its value when used as the lone character in an integer
  character constant.
*/
#if defined (ACE_LACKS_WCHAR_T)
#  if !defined (ACE_WCHAR_T_TYPE)
#    define ACE_WCHAR_T_TYPE long
#  endif /* !ACE_WCHAR_T_TYPE */
   typedef ACE_WCHAR_T_TYPE wchar_t;
#endif /* ACE_LACKS_WCHAR_T */

//  Unsigned integer type of the result of the sizeof operator.
#if defined (ACE_LACKS_SIZE_T)
#  if !defined (ACE_SIZE_T_TYPE)
#    define ACE_SIZE_T_TYPE unsigned int
#  endif /* !ACE_SIZE_T_TYPE */
   typedef ACE_SIZE_T_TYPE size_t;
#endif /* ACE_LACKS_SIZE_T */

#ifdef __cplusplus
}
#endif /* __cplusplus */

#include /**/ "ace/post.h"
#endif /* ACE_OS_INCLUDE_OS_STDDEF_H */