region: update debug check macros
This commit is contained in:
parent
a9c723326b
commit
bb20aec311
@ -49,9 +49,7 @@ region<T>::region (T _x, T _y, size_type _w, size_type _h):
|
|||||||
y (_y),
|
y (_y),
|
||||||
w (_w),
|
w (_w),
|
||||||
h (_h)
|
h (_h)
|
||||||
{
|
{ ; }
|
||||||
DEBUG_ONLY (sanity ());
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//-----------------------------------------------------------------------------
|
//-----------------------------------------------------------------------------
|
||||||
@ -204,8 +202,8 @@ region<T>::operator== (const region& rhs) const
|
|||||||
template <typename T>
|
template <typename T>
|
||||||
void
|
void
|
||||||
region<T>::sanity (void) const {
|
region<T>::sanity (void) const {
|
||||||
CHECK_SOFT (w > 0);
|
CHECK_GE (w, 0);
|
||||||
CHECK_SOFT (h > 0);
|
CHECK_GE (h, 0);
|
||||||
static_assert(!std::is_floating_point<T>::value,
|
static_assert(!std::is_floating_point<T>::value,
|
||||||
"Floating point types need width and height checks");
|
"Floating point types need width and height checks");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user