@ -56,7 +56,7 @@ static void pi_print_trace_infos(FILE* out)
fprintf ( out , " Set `LOG_LEVEL=<name string>` to control logging verbosity level at runtime. The name string is case-sensitive. \n " ) ;
fprintf ( out , " Set `LOG_LEVEL=<name string>` to control logging verbosity level at runtime. The name string is case-sensitive. \n " ) ;
}
}
void prog_info ( FILE * out )
static void prog_info ( FILE * out )
{
{
fprintf ( out , PROG_NAME " v%s - " PROG_DESCRIPTION
fprintf ( out , PROG_NAME " v%s - " PROG_DESCRIPTION
# ifdef DEBUG
# ifdef DEBUG
@ -91,7 +91,9 @@ void usage(FILE* out, int argc, char** argv)
// err: 0 for normal exit and print to stdout.
// err: 0 for normal exit and print to stdout.
// err: nonzero for abnormal exit and print to stderr.
// err: nonzero for abnormal exit and print to stderr.
noreturn void usage_then_exit ( int err , int argc , char * * argv )
//
// noinline: We don't want this hoisted.
noinline noreturn void usage_then_exit ( int err , int argc , char * * argv )
{
{
usage ( err ? stderr : stdout , argc , argv ) ;
usage ( err ? stderr : stdout , argc , argv ) ;
exit ( err ) ;
exit ( err ) ;
@ -162,6 +164,9 @@ inv_args:
// Number of results actually computed by `comp_match_all()` may differ from `hsn` if `abort_on_fail` is true (currently its hardcoded to false but that may change.)
// Number of results actually computed by `comp_match_all()` may differ from `hsn` if `abort_on_fail` is true (currently its hardcoded to false but that may change.)
usize cres = full_result - > num_results ;
usize cres = full_result - > num_results ;
INFO ( " Computed result: Suc. Matched %lu / %lu hs. Full match: %s (first failure: %d) " , cres , hsn , full_result - > all_matched ? " yes " : " no " , full_result - > idx_first_failure ) ;
INFO ( " Computed result: Suc. Matched %lu / %lu hs. Full match: %s (first failure: %d) " , cres , hsn , full_result - > all_matched ? " yes " : " no " , full_result - > idx_first_failure ) ;
//TODO: Print out the aggregate (full_result) results (cres) in a reasonable format.
free ( full_result ) ;
free ( full_result ) ;
# endif
# endif