From: Matthew Fernandez Date: Wed, 10 Nov 2021 01:49:41 +0000 (-0800) Subject: general.h: stop disabling assertions when 'DEBUG' is undefined X-Git-Tag: 2.50.0~35^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=380c8a3a0e29035dc3626464a9bc07651b2ebd61;p=graphviz general.h: stop disabling assertions when 'DEBUG' is undefined The effect of this code was that #including general.h prior to assert.h would disable assertions in your code. Not #including general.h or #including it after assert.h would allow assertions to be controlled through the standard `NDEBUG` mechanism. It is not clear why suppressing assertions like this was ever desirable. This is basically another variant of commit 68bcbbd4ddef4960c7ea6884dda10854b0e012e0. --- diff --git a/lib/sparse/general.h b/lib/sparse/general.h index fee536d1f..9e2efad79 100644 --- a/lib/sparse/general.h +++ b/lib/sparse/general.h @@ -66,12 +66,6 @@ extern unsigned char Verbose; #define REALLOC grealloc #endif /* STANDALONE */ -#ifndef DEBUG -#ifndef NDEBUG -#define NDEBUG /* switch off assert*/ -#endif -#endif - #ifdef DEBUG extern double _statistics[10]; #endif