summaryrefslogtreecommitdiffstats
path: root/tools/h5diff/h5diff_common.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/h5diff/h5diff_common.c')
-rw-r--r--tools/h5diff/h5diff_common.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/tools/h5diff/h5diff_common.c b/tools/h5diff/h5diff_common.c
index 8a49fa0..3f2b8cf 100644
--- a/tools/h5diff/h5diff_common.c
+++ b/tools/h5diff/h5diff_common.c
@@ -31,7 +31,7 @@ const char *progname = "h5diff";
* Command-line options: The user can specify short or long-named
* parameters.
*/
-static const char *s_opts = "hVrvqn:d:p:N";
+static const char *s_opts = "hVrvqn:d:p:Nc";
static struct long_options l_opts[] = {
{ "help", no_arg, 'h' },
{ "version", no_arg, 'V' },
@@ -42,6 +42,7 @@ static struct long_options l_opts[] = {
{ "delta", require_arg, 'd' },
{ "relative", require_arg, 'p' },
{ "nan", no_arg, 'N' },
+ { "compare", no_arg, 'c' },
{ NULL, 0, '\0' }
};
@@ -138,6 +139,9 @@ void parse_command_line(int argc,
case 'N':
options->do_nans = 0;
break;
+ case 'c':
+ options->m_list_not_cmp = 1;
+ break;
}
}
@@ -194,11 +198,15 @@ void parse_command_line(int argc,
if (options->not_cmp==1)
{
- printf("--------------------------------\n");
- printf("Some objects are not comparable\n");
- printf("--------------------------------\n");
- if (!options->m_verbose)
- printf("Use -v for a list of objects.\n");
+ if ( options->m_list_not_cmp == 0 )
+ {
+ printf("--------------------------------\n");
+ printf("Some objects are not comparable\n");
+ printf("--------------------------------\n");
+ printf("Use -c for a list of objects.\n");
+ }
+
+
}
}
@@ -331,6 +339,7 @@ void usage(void)
printf(" -r, --report Report mode. Print differences\n");
printf(" -v, --verbose Verbose mode. Print differences, list of objects\n");
printf(" -q, --quiet Quiet mode. Do not do output\n");
+ printf(" -c, --compare List objects that are not comparable\n");
printf(" -N, --nan Avoid NaNs detection\n");
printf(" -n C, --count=C Print differences up to C number\n");