From d3e940c71c57449ef5de4c87245a0292be12d8c3 Mon Sep 17 00:00:00 2001 From: illiliti Date: Thu, 28 Apr 2022 21:41:44 +0300 Subject: [PATCH] include/float.h: Define DECIMAL_DIG Values were shamelessly stolen from musl libc. Needed for hare compiler. --- include/float.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/float.h b/include/float.h index 35b28f2c..24b7410b 100644 --- a/include/float.h +++ b/include/float.h @@ -38,6 +38,7 @@ #define LDBL_MAX_EXP 16384 #define LDBL_MAX 1.18973149535723176502e+4932L #define LDBL_MAX_10_EXP 4932 +#define DECIMAL_DIG 21 #elif defined __aarch64__ || defined __riscv /* @@ -53,6 +54,7 @@ #define LDBL_MAX_EXP 16384 #define LDBL_MAX 1.18973149535723176508575932662800702e+4932L #define LDBL_MAX_EXP 16384 +#define DECIMAL_DIG 36 #else @@ -66,6 +68,7 @@ #define LDBL_MAX_EXP 1024 #define LDBL_MAX 1.7976931348623157e+308L #define LDBL_MAX_10_EXP 308 +#define DECIMAL_DIG 17 #endif