gcc_assert
Ian Lance Taylor
iant@google.com
Fri Jun 8 18:35:00 GMT 2007
ranjith kumar <ranjit_kumar_b4u@yahoo.co.uk> writes:
> What is the purpose of gcc_assert() function?
> Any resource please.
>
>
> 574 #define gcc_assert(EXPR)
> \
> 575 ((void)(!(EXPR) ? fancy_abort (__FILE__,
> __LINE__, __FUNCTION__), 0 : 0))
> 576 #else
> 577 /* Include EXPR, so that unused variable
> warnings do not occur. */
> 578 #define gcc_assert(EXPR) ((void)(0 && (EXPR)))
> 579 #endif
It's a version of the standard assert function used in the gcc
sources. For gcc's purposes it is better than assert because dumping
core is under the control of the -dH option.
Ian
More information about the Gcc-help
mailing list