File: hstdint.h

package info (click to toggle)
hercules 3.13-9
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 14,392 kB
  • sloc: ansic: 175,124; sh: 8,792; makefile: 760; perl: 149
file content (37 lines) | stat: -rw-r--r-- 1,476 bytes parent folder | download | duplicates (5)
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
/* HSTDINT.H    (c) Copyright Roger Bowler, 2006                     */
/*              Hercules standard integer definitions                */

/*-------------------------------------------------------------------*/
/* The purpose of this file is to define the following typedefs:     */
/*      uint8_t, uint16_t, uint32_t, uint64_t                        */
/*      int8_t, int16_t, int32_t, int64_t                            */
/* For Windows, the MSVC-specific C sized integer types are used.    */
/* For Unix, definitions are included from stdint.h if it exists,    */
/* otherwise from inttypes.h (if it exists), otherwise unistd.h      */
/*-------------------------------------------------------------------*/

#ifndef _HSTDINT_H
#define _HSTDINT_H

#ifdef HAVE_CONFIG_H
  #include <config.h>           /* Hercules build configuration      */
#endif

#if defined(_MSVC_)
  typedef unsigned __int8  uint8_t;
  typedef unsigned __int16 uint16_t;
  typedef unsigned __int32 uint32_t;
  typedef unsigned __int64 uint64_t;
  typedef signed __int8  int8_t;
  typedef signed __int16 int16_t;
  typedef signed __int32 int32_t;
  typedef signed __int64 int64_t;
#elif defined(HAVE_STDINT_H)
  #include <stdint.h>           /* Standard integer definitions      */
#elif defined(HAVE_INTTYPES_H)
  #include <inttypes.h>         /* Fixed size integral types         */
#else
  #include <unistd.h>           /* Unix standard definitions         */
#endif

#endif /*_HSTDINT_H*/