[libc-commits] [libc] [libc] Include FP_* macros in math.h (PR #84996)
Petr Hosek via libc-commits
libc-commits at lists.llvm.org
Tue Mar 12 16:50:26 PDT 2024
https://github.com/petrhosek created https://github.com/llvm/llvm-project/pull/84996
These are used unconditionally by libc++ math.h.
This is related to issue #84879.
>From e02987fe1a14036041de675c167aed42b22eefd2 Mon Sep 17 00:00:00 2001
From: Petr Hosek <phosek at google.com>
Date: Tue, 12 Mar 2024 16:48:35 -0700
Subject: [PATCH] [libc] Include FP_* macros in math.h
These are used unconditionally by libc++ math.h.
This is related to issue #84879.
---
libc/include/llvm-libc-macros/math-macros.h | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/libc/include/llvm-libc-macros/math-macros.h b/libc/include/llvm-libc-macros/math-macros.h
index e67fe4d11b4493..db8a4ea65bd69a 100644
--- a/libc/include/llvm-libc-macros/math-macros.h
+++ b/libc/include/llvm-libc-macros/math-macros.h
@@ -11,6 +11,12 @@
#include "limits-macros.h"
+#define FP_NAN 0
+#define FP_INFINITE 1
+#define FP_ZERO 2
+#define FP_SUBNORMAL 3
+#define FP_NORMAL 4
+
#define MATH_ERRNO 1
#define MATH_ERREXCEPT 2
More information about the libc-commits
mailing list