3 ms·
This is why assert exists. tyger(~)% cat << EOF > main.c ? #include <assert.h> ? ? void main( void ) ? { ? assert( 0 == 1 ) ; ? } ? EOF tyger(~)% gc
by mdakin 18y ago
This is why assert exists.
tyger(~)% cat << EOF > main.c
? #include <assert.h>
?
? void main( void )
? {
? assert( 0 == 1 ) ;
? }
? EOF
tyger(~)% gcc main.c
main.c: In function ‘main’:
main.c:4: warning: return type of ‘main’ is not ‘int’
tyger(~)% ./a.out
Assertion failed: (0 == 1), function main, file main.c, line 5.
Abort
tyger(~)%