summaryrefslogtreecommitdiff
path: root/ext/ffi/prelude.h
diff options
context:
space:
mode:
authorDivy Srivastava <dj.srivastava23@gmail.com>2022-07-24 18:38:13 +0530
committerGitHub <noreply@github.com>2022-07-24 18:38:13 +0530
commit58d1126fa43ac429d4fcdfc3914abf1ccca93bc5 (patch)
tree30103109173e6cc8f491e5e2325c25a3111bc30a /ext/ffi/prelude.h
parentf8fee6cd21cce82d6c34e539d39da86df7b036f7 (diff)
chore(ext/ffi): remove dependency on stdint.h (#15294)
Diffstat (limited to 'ext/ffi/prelude.h')
-rw-r--r--ext/ffi/prelude.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/ext/ffi/prelude.h b/ext/ffi/prelude.h
new file mode 100644
index 000000000..ed3d14e1a
--- /dev/null
+++ b/ext/ffi/prelude.h
@@ -0,0 +1,19 @@
+// Copyright 2018-2022 the Deno authors. All rights reserved. MIT license.
+
+/* Exact integral types. */
+
+/* Signed. */
+typedef signed char int8_t;
+typedef short int int16_t;
+typedef int int32_t;
+typedef long int int64_t;
+
+/* Unsigned. */
+typedef unsigned char uint8_t;
+typedef unsigned short int uint16_t;
+typedef unsigned int uint32_t;
+typedef unsigned long int uint64_t;
+
+/* Types for `void *' pointers. */
+typedef long int intptr_t;
+typedef unsigned long int uintptr_t;