From e613b5c6246aad3bc5331e0b007e66073e4e8e6d Mon Sep 17 00:00:00 2001 From: Patrick Pelissier Date: Fri, 25 Mar 2022 22:45:08 +0100 Subject: [PATCH] Proper define of NDEBUG to avoid adding assertions in string benchmarks --- bench/bench-string-2.cpp | 2 ++ bench/bench-string.cpp | 3 ++- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/bench/bench-string-2.cpp b/bench/bench-string-2.cpp index efb3f291..ac3de6b4 100644 --- a/bench/bench-string-2.cpp +++ b/bench/bench-string-2.cpp @@ -22,6 +22,8 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#define NDEBUG + #include #include #include diff --git a/bench/bench-string.cpp b/bench/bench-string.cpp index 555b77ff..580c43e7 100644 --- a/bench/bench-string.cpp +++ b/bench/bench-string.cpp @@ -48,11 +48,12 @@ * */ +#define NDEBUG + #include #include #include -#define NDEBUG #define M_USE_SMALL_NAME 0 #include "common.h"