From 80e8980b0972baf1d8cedd1c0a546dc0ae3ca3f4 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Alexis=20Laferri=C3=A8re?= Date: Tue, 1 Sep 2015 14:25:56 -0400 Subject: [PATCH] contrib/objcwrapper: print opts errors, not just usage MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Alexis Laferrière --- contrib/objcwrapper/src/objcwrapper.nit | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/contrib/objcwrapper/src/objcwrapper.nit b/contrib/objcwrapper/src/objcwrapper.nit index 0b8bb72..6ec6b6b 100644 --- a/contrib/objcwrapper/src/objcwrapper.nit +++ b/contrib/objcwrapper/src/objcwrapper.nit @@ -32,7 +32,9 @@ opts.add_option(opt_help, opt_output, opt_init_as_methods, opt_gcc_options) opts.parse args if opts.errors.not_empty or opts.rest.is_empty or opt_help.value then - print """ + if opts.errors.not_empty then print_error opts.errors.join("\n") + + print_error """ Usage: objcwrapper [options] input_file [other_input_file [...]] Options:""" opts.usage -- 1.7.9.5