Skip to content

Commit

Permalink
More concise failure descriptions.
Browse files Browse the repository at this point in the history
  • Loading branch information
kr committed Dec 15, 2008
1 parent e1c702e commit c5cd9f0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions cut.c
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ static void print_string( char *string )

static void print_string_as_error( char *filename, int lineNumber, char *string )
{
printf( " %s(%d): %s", filename, lineNumber, string );
printf( " %s:%d: %s", filename, lineNumber, string );
fflush( stdout );
}

Expand Down Expand Up @@ -181,10 +181,10 @@ void __cut_assert(
{
if (success) return;

print_string_as_error( filename, lineNumber, message );
new_line();
print_string_as_error( filename, lineNumber, "Failed expression: " );
print_string_as_error( filename, lineNumber, "(" );
print_string( expression );
print_string(") ");
print_string( message );
new_line();

cur_takedown();
Expand Down

0 comments on commit c5cd9f0

Please sign in to comment.