aboutsummaryrefslogtreecommitdiff
path: root/src/parse_f128.h
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2019-03-22 14:56:03 -0400
committerAndrew Kelley <andrew@ziglang.org>2019-03-22 14:56:03 -0400
commit4615ed5ea003516c8235728ac3f5f0ee2ccea8a7 (patch)
tree15d8bf63d72a2c343c13242031f02e746183137e /src/parse_f128.h
parent127bb124a06dc93f4def23224d400f4050754674 (diff)
downloadzig-4615ed5ea003516c8235728ac3f5f0ee2ccea8a7.tar.gz
zig-4615ed5ea003516c8235728ac3f5f0ee2ccea8a7.zip
float literals now parse using musl's 128 bit float code
fixes float literals not having 128 bit precision
Diffstat (limited to 'src/parse_f128.h')
-rw-r--r--src/parse_f128.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/src/parse_f128.h b/src/parse_f128.h
new file mode 100644
index 0000000000..684b666024
--- /dev/null
+++ b/src/parse_f128.h
@@ -0,0 +1,23 @@
+/*
+ * Copyright (c) 2015 Andrew Kelley
+ *
+ * This file is part of zig, which is MIT licensed.
+ * See http://opensource.org/licenses/MIT
+ */
+
+#ifndef ZIG_PARSE_F128_H
+#define ZIG_PARSE_F128_H
+
+#include "softfloat_types.h"
+
+#ifdef __cplusplus
+#define ZIG_EXTERN_C extern "C"
+#define ZIG_RESTRICT
+#else
+#define ZIG_EXTERN_C
+#define ZIG_RESTRICT restrict
+#endif
+
+ZIG_EXTERN_C float128_t parse_f128(const char *ZIG_RESTRICT s, char **ZIG_RESTRICT p);
+
+#endif