Remove Min and Max functions (#14)

The functions were conflicting with some Arduino Due macros and they weren't being used, so they've been removed.
pull/15/head
Pharap 6 years ago committed by GitHub
parent 4f8fe99153
commit 05f8ae0c83
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 24
      src/FixedPoints/Details.h

@ -47,30 +47,6 @@ namespace FIXED_POINTS_DETAILS
constexpr static const auto Value = sizeof(T) * CHAR_BIT;
};
template< typename T, typename U = T >
constexpr auto Max(const T & left, const U & right) noexcept -> decltype((left > right) ? left : right)
{
return (left > right) ? left : right;
}
template< typename T, T Left, T Right >
constexpr auto Max(void) noexcept -> decltype((Left > Right) ? Left : Right)
{
return (Left > Right) ? Left : Right;
}
template< typename T, typename U = T >
constexpr auto Min(const T & left, const U & right) noexcept -> decltype((left < right) ? left : right)
{
return (left < right) ? left : right;
}
template< typename T, T Left, T Right >
constexpr auto Min(void) noexcept -> decltype((Left < Right) ? Left : Right)
{
return (Left < Right) ? Left : Right;
}
template< bool Condition, typename TTrue, typename TFalse >
struct Conditional;

Loading…
Cancel
Save