From e445e27874ae686a2ad284c3ccd5b58730585f41 Mon Sep 17 00:00:00 2001 From: Jan Nieuwenhuizen Date: Thu, 14 Apr 2005 20:19:07 +0000 Subject: [PATCH] (old-relative-not-used-message) (version-not-seen-message): Add input-file-name-location to message. --- ChangeLog | 3 +++ lily/lily-parser.cc | 2 -- ly/init.ly | 10 ++++------ scm/lily-library.scm | 16 ++++++++++++---- stepmake/stepmake/po-targets.make | 3 +-- 5 files changed, 20 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index e5b6cb72ee..641f2848ff 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2005-04-14 Jan Nieuwenhuizen + * scm/lily-library.scm (old-relative-not-used-message) + (version-not-seen-message): Add input-file-name-location to message. + * lily/parser.yy (lilypond): Add token aliases. * Documentation/user/music-glossary.tely (accidental): Fixes. Do diff --git a/lily/lily-parser.cc b/lily/lily-parser.cc index c63f6c531c..cef4ed6836 100644 --- a/lily/lily-parser.cc +++ b/lily/lily-parser.cc @@ -168,8 +168,6 @@ Lily_parser::here_str0 () const void Lily_parser::parser_error (String s) { - /* FIXME: cannot otherwise internationalize this bison warning. */ - (void) _i ("syntax error, unexpected "); lexer_->here_input ().error (_ (s.to_str0 ())); error_level_ = 1; } diff --git a/ly/init.ly b/ly/init.ly index 04fa987483..cf7245980c 100644 --- a/ly/init.ly +++ b/ly/init.ly @@ -27,13 +27,11 @@ #(if (and (ly:get-option 'old-relative) (defined? 'input-file-name) (not (ly:get-option 'old-relative-used))) - (ly:warning (string-append - "\n" - input-file-name ": old relative compatibility was not used." - )))%% there is a problem at the end of the input file + (old-relative-not-used-message input-file-name))%% there is a problem at the end of the input file -#(if (not version-seen?) - (version-not-seen-message)) +#(if (and (not version-seen?) + (defined? 'input-file-name)) + (version-not-seen-message input-file-name)) #(if (pair? toplevel-scores) (ly:parser-print-book parser diff --git a/scm/lily-library.scm b/scm/lily-library.scm index 77938bd9b4..2d25a3991f 100644 --- a/scm/lily-library.scm +++ b/scm/lily-library.scm @@ -339,8 +339,16 @@ possibly turned off." (debugf "design:~S\n" designsize) scaling)) -(define-public (version-not-seen-message) - (ly:warning +(define-public (version-not-seen-message input-file-name) + (ly:message + (string-append + input-file-name ": 0: " (_ "warning: ") (format #f - (_ "No \\version statement found. Add~afor future compatibility.") - (format #f "\n\n\\version ~s\n\n" (lilypond-version))))) + (_ "no \\version statement found, add~afor future compatibility") + (format #f "\n\n\\version ~s\n\n" (lilypond-version)))))) + +(define-public (old-relative-not-used-message input-file-name) + (ly:message + (string-append + input-file-name ": 0: " (_ "warning: ") + (_ "old relative compatibility not used")))) diff --git a/stepmake/stepmake/po-targets.make b/stepmake/stepmake/po-targets.make index fe84a76fb6..bdad9633e6 100644 --- a/stepmake/stepmake/po-targets.make +++ b/stepmake/stepmake/po-targets.make @@ -23,8 +23,7 @@ ifneq ($(strip $(ALL_PO_SOURCES)),) @echo $(ALL_PO_SOURCES) xgettext --default-domain=$(package) --join \ --output-dir=$(po-dir)/$(outdir) --add-comments \ - --keyword=_ --keyword=_f --keyword=_i \ - --keyword=yyerror \ + --keyword=_ --keyword=_f --keyword=_i $(XGETTEXT_FLAGS) $(ALL_PO_SOURCES) endif endif -- 2.39.5