From 7c1eda9eec81468c7083877f88f94b0dbd3ef068 Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Mon, 27 Feb 2012 05:05:58 -0800 Subject: * match.c (extract): Check for negative value of opt_nobindings, which forces the printing. * txr.c (help): Under -b, mention that printing the word false is suppressed also. Added documentation for -B. (main): Implemented -B option. * txr.1: Documented -B option and added clarifying text under -b option explaining the conditions under which bindings are printed. --- txr.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'txr.c') diff --git a/txr.c b/txr.c index 9dc083a9..92893ebe 100644 --- a/txr.c +++ b/txr.c @@ -90,8 +90,11 @@ static void help(void) "-Dvar Predefine variable var, with empty string value.\n" "-q Quiet: don't report errors during query matching.\n" "-v Verbose: extra logging from matcher.\n" -"-b Don't dump list of bindings.\n" -"-l If dumping bindings, use a Lisp format.\n" +"-b Don't dump list of bindings, or 'false'\n" +" on unsuccessful termination.\n" +"-B Force list of bindings to be dumped, or false\n" +" if termination is unsuccessful.\n" +"-l If dumping bindings, use TXR Lisp format.\n" "-d Debugger mode.\n" "-a num Generate array variables up to num-dimensions.\n" " Default is 1. Additional dimensions are fudged\n" @@ -329,6 +332,9 @@ int txr_main(int argc, char **argv) case 'b': opt_nobindings = 1; break; + case 'B': + opt_nobindings = -1; + break; case 'l': opt_lisp_bindings = 1; break; -- cgit v1.2.3