[libc-commits] [libc] [libc][math][NFC] Fix nextafterl build (PR #195599)

Muhammad Bassiouni via libc-commits libc-commits at lists.llvm.org
Mon May 4 00:15:06 PDT 2026


https://github.com/bassiounix created https://github.com/llvm/llvm-project/pull/195599

None

>From 23ec237cc2f114dcb1b29ae013f89bbd78e75a5e Mon Sep 17 00:00:00 2001
From: bassiounix <muhammad.m.bassiouni at gmail.com>
Date: Mon, 4 May 2026 10:14:24 +0300
Subject: [PATCH] [libc][math][NFC] Fix nextafterl build

---
 libc/src/__support/FPUtil/x86_64/NextAfterLongDouble.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libc/src/__support/FPUtil/x86_64/NextAfterLongDouble.h b/libc/src/__support/FPUtil/x86_64/NextAfterLongDouble.h
index 74a991d40115e..aa9f4a5e39c2d 100644
--- a/libc/src/__support/FPUtil/x86_64/NextAfterLongDouble.h
+++ b/libc/src/__support/FPUtil/x86_64/NextAfterLongDouble.h
@@ -24,7 +24,7 @@
 namespace LIBC_NAMESPACE_DECL {
 namespace fputil {
 
-LIBC_INLINE long double nextafter(long double from, long double to) {
+LIBC_INLINE constexpr long double nextafter(long double from, long double to) {
   using FPBits = FPBits<long double>;
   FPBits from_bits(from);
   if (from_bits.is_nan())



More information about the libc-commits mailing list