[geos-devel] assert.h / assert()

Stephen Woodbridge woodbri at swoodbridge.com
Tue Jan 31 18:31:23 EST 2006

strk at refractions.net wrote:
> Is there any known problem in using assert.h with GEOS ?
> I'm asking as I know there have been issues with stdio.h
> in the past, but I'd like to be able using assert()
> or any equivalent standard C++ thing to easy debugging.

Why not wrap is in a #define like

#ifdef DEBUG
#define ASSERT(x) assert(x)
#define ASSERT(x)

or something like that. Then it is easy to add it to the source but 
exclude when required.

-Steve W.

More information about the geos-devel mailing list