git.postgresql.org Git - postgresql.git/commitdiff

git projects / postgresql.git / commitdiff
? search:
summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 14ba9fd)
Arrange that the string "syntax error" generated by bison is translated.
2009年6月10日 23:11:52 +0000 (23:11 +0000)
2009年6月10日 23:11:52 +0000 (23:11 +0000)

diff --git a/src/interfaces/ecpg/preproc/ecpg.header b/src/interfaces/ecpg/preproc/ecpg.header
index faaf607c610f3ebd3055d2f481e5064fc5e99f9b..c2091d28293c12feea9439a6118ac8fb06dedb11 100644 (file)
--- a/src/interfaces/ecpg/preproc/ecpg.header
+++ b/src/interfaces/ecpg/preproc/ecpg.header
@@ -1,4 +1,4 @@
-/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/ecpg.header,v 1.6 2009年06月03日 20:24:51 tgl Exp $ */
+/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/ecpg.header,v 1.7 2009年06月10日 23:11:52 petere Exp $ */
/* Copyright comment */
%{
@@ -22,6 +22,12 @@
*/
#define base_yylex filtered_base_yylex
+/*
+ * This is only here so the string gets into the POT. Bison uses it
+ * internally.
+ */
+#define bison_gettext_dummy gettext_noop("syntax error")
+
/*
* Variables containing simple states.
*/
diff --git a/src/interfaces/ecpg/preproc/ecpg.trailer b/src/interfaces/ecpg/preproc/ecpg.trailer
index 718e74a9b303a5232242f607ed04f6c50225ed0b..1b287e4c65d694e4fd4fa78bed8ad14f73c4fc02 100644 (file)
--- a/src/interfaces/ecpg/preproc/ecpg.trailer
+++ b/src/interfaces/ecpg/preproc/ecpg.trailer
@@ -1,4 +1,4 @@
-/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/ecpg.trailer,v 1.8 2009年06月03日 20:24:51 tgl Exp $ */
+/* $PostgreSQL: pgsql/src/interfaces/ecpg/preproc/ecpg.trailer,v 1.9 2009年06月10日 23:11:52 petere Exp $ */
statements: /*EMPTY*/
| statements statement
@@ -1987,8 +1987,9 @@ ecpg_into: INTO into_list { $$ = EMPTY; }
void base_yyerror(const char *error)
{
+ /* translator: %s is typically the translation of "syntax error" */
mmerror(PARSE_ERROR, ET_ERROR, "%s at or near \"%s\"",
- error, token_start ? token_start : yytext);
+ _(error), token_start ? token_start : yytext);
}
void parser_init(void)
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /