From cad73fae9dbed47eb66674609ba617ca01b97261 Mon Sep 17 00:00:00 2001 From: Davis King Date: Mon, 9 May 2016 21:46:04 -0400 Subject: [PATCH] Fixed compiler warnings --- dlib/dnn/layers.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/dlib/dnn/layers.h b/dlib/dnn/layers.h index 6b9096e76..6d926f869 100644 --- a/dlib/dnn/layers.h +++ b/dlib/dnn/layers.h @@ -251,9 +251,9 @@ namespace dlib static_assert(_nc >= 0, "The number of columns in a filter must be >= 0"); static_assert(_stride_y > 0, "The filter stride must be > 0"); static_assert(_stride_x > 0, "The filter stride must be > 0"); - static_assert(0 <= _padding_y && (_nr==0 && _padding_y == 0 || _nr!=0 && _padding_y < _nr), + static_assert(0 <= _padding_y && ((_nr==0 && _padding_y == 0) || (_nr!=0 && _padding_y < _nr)), "The padding must be smaller than the filter size, unless the filters size is 0."); - static_assert(0 <= _padding_x && (_nc==0 && _padding_x == 0 || _nc!=0 && _padding_x < _nc), + static_assert(0 <= _padding_x && ((_nc==0 && _padding_x == 0) || (_nc!=0 && _padding_x < _nc)), "The padding must be smaller than the filter size, unless the filters size is 0."); public: @@ -429,9 +429,9 @@ namespace dlib static_assert(_nc >= 0, "The number of columns in a filter must be >= 0"); static_assert(_stride_y > 0, "The filter stride must be > 0"); static_assert(_stride_x > 0, "The filter stride must be > 0"); - static_assert(0 <= _padding_y && (_nr==0 && _padding_y == 0 || _nr!=0 && _padding_y < _nr), + static_assert(0 <= _padding_y && ((_nr==0 && _padding_y == 0) || (_nr!=0 && _padding_y < _nr)), "The padding must be smaller than the filter size, unless the filters size is 0."); - static_assert(0 <= _padding_x && (_nc==0 && _padding_x == 0 || _nc!=0 && _padding_x < _nc), + static_assert(0 <= _padding_x && ((_nc==0 && _padding_x == 0) || (_nc!=0 && _padding_x < _nc)), "The padding must be smaller than the filter size, unless the filters size is 0."); avg_pool_(