File: pt_stdint.h

package info (click to toggle)
libpano13 2.9.19+dfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 8,736 kB
  • ctags: 3,225
  • sloc: ansic: 34,695; sh: 11,214; makefile: 311; perl: 242
file content (45 lines) | stat: -rw-r--r-- 1,152 bytes parent folder | download | duplicates (3)
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
/* 
 * This file is created to guarantee compatibility with MS Compiler
 *
 * Under GNU gcc, data types are defined based on their lenght, but under
 * MSC, they don't exist, so here they are defined
 *
 * pt_stdint.h */
#ifndef PT_STDINT__H
#define PT_STDINT__H

// define some int
#if defined _MSC_VER && _MSC_VER<1600 /* Microsoft Visual C++ */
   typedef signed char             int8_t;
   typedef short int               int16_t;
   typedef int                     int32_t;
   typedef __int64                 int64_t;
    
   typedef unsigned char             uint8_t;
   typedef unsigned short int        uint16_t;
   typedef unsigned int              uint32_t;
   /* no uint64_t */
   
   #define INT32_MAX _I32_MAX
# else /* #ifdef _MSC_VER */
   #include <stdint.h>
#endif /* #ifdef _MSC_VER */

#ifdef _MSC_VER
   #define vsnprintf _vsnprintf
   #define snprintf _snprintf
   
   #ifdef _CPLUSPLUS
   /* define if your compiler understands inline commands */
   #define INLINE _inline
   #else
   #define INLINE
   #endif
# else /* #ifdef _MSC_VER */
   #ifndef INLINE
   #define INLINE inline
   #endif
#endif /* #ifdef _MSC_VER */

#endif