Commit e8afa273 e8afa2739cb95c3821f9c92fb89f24e6b9f9f584 by Sergey Poznyakoff

New command line option --debug.

1 parent 0aa6344c
...@@ -29,7 +29,7 @@ static struct argp_option options[] = { ...@@ -29,7 +29,7 @@ static struct argp_option options[] = {
29 {"form", 'F', N_("FILE"), 0, N_("Read format from given file")}, 29 {"form", 'F', N_("FILE"), 0, N_("Read format from given file")},
30 {"format", 't', N_("FORMAT"), 0, N_("Use this format string")}, 30 {"format", 't', N_("FORMAT"), 0, N_("Use this format string")},
31 {"dump", 'd', NULL, 0, N_("Dump the listing of compiled format code")}, 31 {"dump", 'd', NULL, 0, N_("Dump the listing of compiled format code")},
32 32 { "debug", 'D', NULL, 0, N_("Enable parser debugging output"),},
33 { 0 } 33 { 0 }
34 }; 34 };
35 35
...@@ -75,6 +75,10 @@ opt_handler (int key, char *arg, void *unused) ...@@ -75,6 +75,10 @@ opt_handler (int key, char *arg, void *unused)
75 case 'd': 75 case 'd':
76 action = action_dump; 76 action = action_dump;
77 break; 77 break;
78
79 case 'D':
80 mh_format_debug (1);
81 break;
78 82
79 default: 83 default:
80 return 1; 84 return 1;
......