llvm/libc/test/src/stdlib/strtold_test.cpp

//===-- Unittests for strtold ---------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//

#include "src/__support/FPUtil/FPBits.h"
#include "src/__support/uint128.h"
#include "src/errno/libc_errno.h"
#include "src/stdlib/strtold.h"

#include "test/UnitTest/Test.h"

#include <stddef.h>

#if defined(LIBC_TYPES_LONG_DOUBLE_IS_FLOAT64)
#define SELECT_CONST
#elif defined(LIBC_TYPES_LONG_DOUBLE_IS_X86_FLOAT80)
#define SELECT_CONST(_, val, __)
#elif defined(LIBC_TYPES_LONG_DOUBLE_IS_FLOAT128)
#define SELECT_CONST
#else
#error "Unknown long double type"
#endif

class LlvmLibcStrToLDTest : public LIBC_NAMESPACE::testing::Test {};

TEST_F(LlvmLibcStrToLDTest, SimpleTest) {}

// These are tests that have caused problems for doubles in the past.
TEST_F(LlvmLibcStrToLDTest, Float64SpecificFailures) {}

TEST_F(LlvmLibcStrToLDTest, Float80SpecificFailures) {}

TEST_F(LlvmLibcStrToLDTest, MaxSizeNumbers) {}

// These tests check subnormal behavior for 80 bit and 128 bit floats. They will
// be too small for 64 bit floats.
TEST_F(LlvmLibcStrToLDTest, SubnormalTests) {}

TEST_F(LlvmLibcStrToLDTest, SmallNormalTests) {}

TEST_F(LlvmLibcStrToLDTest, ComplexHexadecimalTests) {}

TEST_F(LlvmLibcStrToLDTest, InfTests) {}

TEST_F(LlvmLibcStrToLDTest, NaNTests) {}