mirror of
https://github.com/EnderIce2/Fennix.git
synced 2025-05-25 22:14:34 +00:00
feat(kernel/std): ✨ add is_floating_point type trait
This commit is contained in:
parent
75d51fb9d9
commit
c491351fd0
@ -721,4 +721,12 @@ namespace std
|
||||
|
||||
template <class T>
|
||||
constexpr bool is_pointer_v = is_pointer<T>::value;
|
||||
|
||||
template <class T>
|
||||
struct is_floating_point : std::integral_constant<bool, std::is_same<float, typename std::remove_cv<T>::type>::value || std::is_same<double, typename std::remove_cv<T>::type>::value || std::is_same<long double, typename std::remove_cv<T>::type>::value>
|
||||
{
|
||||
};
|
||||
|
||||
template <class T>
|
||||
constexpr bool is_floating_point_v = is_floating_point<T>::value;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user