* lib/Autom4te/General.pm (getopt): Do not silence the note channel based on --verbose. * lib/Autom4te/FileUtils.pm (update_file): Use the verbose channel for messages. * tests/m4sugar.at: Extend expected output, because -Werror prints now something.
Signed-off-by: Bert Wesarg <[email protected]> --- lib/Autom4te/FileUtils.pm | 6 +++--- lib/Autom4te/General.pm | 1 - tests/m4sugar.at | 3 ++- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/Autom4te/FileUtils.pm b/lib/Autom4te/FileUtils.pm index 150db33..71c3791 100644 --- a/lib/Autom4te/FileUtils.pm +++ b/lib/Autom4te/FileUtils.pm @@ -182,7 +182,7 @@ sub update_file ($$;$) if (!$force && -f "$to" && compare ("$from", "$to") == 0) { # File didn't change, so don't update its mod time. - msg 'note', "`$to' is unchanged"; + verb "`$to' is unchanged"; unlink ($from) or fatal "cannot remove $from: $!"; return @@ -195,13 +195,13 @@ sub update_file ($$;$) or fatal "cannot backup $to: $!"; move ("$from", "$to") or fatal "cannot rename $from as $to: $!"; - msg 'note', "`$to' is updated"; + verb "`$to' is updated"; } else { move ("$from", "$to") or fatal "cannot rename $from as $to: $!"; - msg 'note', "`$to' is created"; + verb "`$to' is created"; } } diff --git a/lib/Autom4te/General.pm b/lib/Autom4te/General.pm index 80e6efa..3a00618 100644 --- a/lib/Autom4te/General.pm +++ b/lib/Autom4te/General.pm @@ -277,7 +277,6 @@ sub getopt (%) push @ARGV, '-' if $stdin; - setup_channel 'note', silent => !$verbose; setup_channel 'verb', silent => !$verbose; } diff --git a/tests/m4sugar.at b/tests/m4sugar.at index cbe602d..a44ede5 100644 --- a/tests/m4sugar.at +++ b/tests/m4sugar.at @@ -285,7 +285,8 @@ script.4s:8: the top level ]) AT_CHECK_M4SUGAR([-o- -Wnone,cross,error], 1, [], -[[script.4s:6: warning: cross +[[autom4te: warnings are treated as errors +script.4s:6: warning: cross script.4s:2: cross_warning is expanded from... script.4s:6: the top level script.4s:8: warning: cross -- 1.7.7.931.gdbe98
