[PATCH] add gcc_assert

Geoffrey Keating geoffk@geoffk.org
Mon Aug 30 18:58:00 GMT 2004


Nathan Sidwell <nathan@codesourcery.com> writes:

> This patch implements gcc_assert & gcc_unreachable along with
> a checking flag --enable-checking=assert.
> 
> --disable-checking will disable asserts, the default is to
> enable them.
> 
> I'm not sure how
> 	# Enable some checks by default for development versions of GCC
> gets turned into
> 	# By default, disable all checks for release versions of GCC.
> for releases. Can someone clue me in please? I'll set the default
> to enable the assertions on relases too.
> 
> built on i686-pc-linux-gnu with a manual assert in toplev.c.

Could you implement --enable-checking=release as an interface to
switch on exactly those checks that are switched on in a release
branch?  That will save people having to read the documentation of
each release (there will be documentation, right?) to find out which
checking things are switched on in that release.



More information about the Gcc-patches mailing list