This repository has been archived on 2024-12-16. You can view files and clone it, but cannot push or open issues or pull requests.
CodeBlocksPortable/WATCOM/samples/clibexam/assert.c

17 lines
298 B
C

#include <stdio.h>
#include <assert.h>
void process_string( char *string )
{
/* use assert to check argument */
assert( string != NULL );
assert( *string != '\0' );
/* rest of code follows here */
}
void main()
{
process_string( "hello" );
process_string( "" );
}