WPILibC++ 2023.4.3-108-ge5452e3
copysign.hpp File Reference

Go to the source code of this file.

Functions

template<typename T1 , typename T2 >
constexpr T1 copysign (const T1 x, const T2 y) noexcept
 Compile-time copy sign function. More...
 

Function Documentation

◆ copysign()

template<typename T1 , typename T2 >
constexpr T1 copysign ( const T1  x,
const T2  y 
)
constexprnoexcept

Compile-time copy sign function.

Parameters
xa real-valued input
ya real-valued input
Returns
replace the signbit of x with the signbit of y.