File: stdint.h

package info (click to toggle)
emacs25 25.1%2B1-4%2Bdeb9u1
  • links: PTS
  • area: main
  • in suites: stretch
  • size: 131,428 kB
  • ctags: 97,538
  • sloc: lisp: 1,107,716; ansic: 305,108; objc: 16,577; makefile: 5,931; sh: 2,547; perl: 1,567; yacc: 1,566; cpp: 1,287; xml: 1,110; php: 1,035; pascal: 1,011; python: 831; cs: 770; ada: 725; awk: 640; ruby: 396; erlang: 153; java: 27
file content (72 lines) | stat: -rw-r--r-- 2,208 bytes parent folder | download
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
/* Replacement stdint.h file for building GNU Emacs on Windows.

Copyright (C) 2011-2016 Free Software Foundation, Inc.

This file is part of GNU Emacs.

GNU Emacs is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or (at
your option) any later version.

GNU Emacs is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with GNU Emacs.  If not, see <http://www.gnu.org/licenses/>.  */

#ifndef _NT_STDINT_H_
#define _NT_STDINT_H_

#ifdef __GNUC__
# include_next <stdint.h> /* use stdint.h if available */
#else	/* !__GNUC__ */

/* Minimum definitions to allow compilation with tool chains where
   stdint.h is not available, e.g. Microsoft Visual Studio.  */

#ifdef _WIN64
typedef __int64 intptr_t;
typedef unsigned int uint32_t;
typedef unsigned __int64 uint64_t;
#define UINT64_MAX (18446744073709551615i64)
#define UINT64_MIN 0
/* "i64" is the non-standard suffix used by MSVC for 64-bit constants.  */
#define INT64_MAX 9223372036854775807i64
#define INT64_MIN (~INT64_MAX)
#define INTPTR_MAX INT64_MAX
#define INTPTR_MIN INT64_MIN
#define UINTPTR_MAX UINT64_MAX
#define UINTMAX_MAX UINT64_MAX
#define UINTMAX_MIN UINT64_MIN
#define INTMAX_MAX INT64_MAX
#define INTMAX_MIN INT64_MIN
#define uintmax_t unsigned __int64
#define intmax_t __int64
#else
typedef int intptr_t;
typedef unsigned int uint32_t;
#define UINT32_MAX 4294967295
#define UINT32_MIN 0
#define INT32_MAX 2147483647
#define INT32_MIN (~INT32_MAX)
#define INTPTR_MAX INT32_MAX
#define INTPTR_MIN INT32_MIN
#define UINTPTR_MAX UINT32_MAX
#define UINTMAX_MAX UINT32_MAX
#define UINTMAX_MIN UINT32_MIN
#define INTMAX_MAX INT32_MAX
#define INTMAX_MIN INT32_MIN
#define uintmax_t unsigned long
#define intmax_t long
#endif

#define PTRDIFF_MAX INTPTR_MAX
#define PTRDIFF_MIN INTPTR_MIN
#define SIZE_MAX UINTPTR_MAX

#endif	/* !__GNUC__ */

#endif /* _NT_STDINT_H_ */