aboutsummaryrefslogtreecommitdiff
path: root/src/html.gram.y
diff options
context:
space:
mode:
Diffstat (limited to 'src/html.gram.y')
-rw-r--r--src/html.gram.y34
1 files changed, 17 insertions, 17 deletions
diff --git a/src/html.gram.y b/src/html.gram.y
index fae64ff..e488494 100644
--- a/src/html.gram.y
+++ b/src/html.gram.y
@@ -110,13 +110,13 @@ expr : value
{
if ($1.type == unspecified_value
|| $3.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($1.type != $3.type)
{
- yyerror ("type mismatch in addition");
+ yyerror (_("type mismatch in addition"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$.type = $1.type;
deduce_format (&$$, &$1, &$3);
@@ -142,18 +142,18 @@ expr : value
{
if ($1.type == unspecified_value
|| $3.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($1.type != $3.type)
{
- yyerror ("type mismatch in subtraction");
+ yyerror (_("type mismatch in subtraction"));
init_value (&$$, unspecified_value, NULL);
}
else if ($1.type == string_value)
{
- yyerror ("subtraction not defined for strings");
+ yyerror (_("subtraction not defined for strings"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$.type = $1.type;
deduce_format (&$$, &$1, &$3);
@@ -164,18 +164,18 @@ expr : value
{
if ($1.type == unspecified_value
|| $3.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($1.type != $3.type)
{
- yyerror ("type mismatch in multiplication");
+ yyerror (_("type mismatch in multiplication"));
init_value (&$$, unspecified_value, NULL);
}
else if ($1.type == string_value)
{
- yyerror ("multiplication not defined for strings");
+ yyerror (_("multiplication not defined for strings"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$.type = $1.type;
deduce_format (&$$, &$1, &$3);
@@ -186,23 +186,23 @@ expr : value
{
if ($1.type == unspecified_value
|| $3.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($1.type != $3.type)
{
- yyerror ("type mismatch in division");
+ yyerror (_("type mismatch in division"));
init_value (&$$, unspecified_value, NULL);
}
else if ($1.type == string_value)
{
- yyerror ("division not defined for strings");
+ yyerror (_("division not defined for strings"));
init_value (&$$, unspecified_value, NULL);
}
else if (fabs ($3.v.number) < 1.0e-5)
{
- yyerror ("division by zero");
+ yyerror (_("division by zero"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$.type = $1.type;
deduce_format (&$$, &$1, &$3);
@@ -212,13 +212,13 @@ expr : value
| '-' expr %prec UMINUS
{
if ($2.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($2.type == string_value)
{
- yyerror ("unary minus not defined for strings");
+ yyerror (_("unary minus not defined for strings"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$ = $2;
$$.v.number = - $2.v.number;
@@ -227,13 +227,13 @@ expr : value
| '+' expr %prec UMINUS
{
if ($2.type == unspecified_value)
init_value (&$$, unspecified_value, NULL);
else if ($2.type == string_value)
{
- yyerror ("unary plus not defined for strings");
+ yyerror (_("unary plus not defined for strings"));
init_value (&$$, unspecified_value, NULL);
}
else
{
$$ = $2;
}
@@ -270,33 +270,33 @@ create_html (pp_tab_t *tab, char *file, char *dest)
tmp_file_name = mkfilename (NULL, dest, ".tmp");
tmp_file = fopen (tmp_file_name, "w");
if (!tmp_file)
{
- logmsg (L_ERR, "cannot open output file `%s': %s",
+ logmsg (L_ERR, _("cannot open output file `%s': %s"),
file, strerror (errno));
html_close ();
return 1;
}
ident_tab = tab;
rc = yyparse ();
fclose (tmp_file);
if (rc == 0)
{
if (unlink (dest) && errno != ENOENT)
{
- logmsg (L_ERR, "cannot unlink file `%s': %s",
+ logmsg (L_ERR, _("cannot unlink file `%s': %s"),
dest, strerror (errno));
rc = 1;
}
if (rename (tmp_file_name, dest))
{
- logmsg (L_ERR, "cannot rename `%s' to `%s': %s",
+ logmsg (L_ERR, _("cannot rename `%s' to `%s': %s"),
tmp_file_name, dest,
strerror (errno));
rc = 1;
}
}
free (tmp_file_name);
@@ -491,22 +491,22 @@ read_symtab (pp_tab_t **tab, const char *name)
continue;
p = buf;
cmd = *p++;
if (*p != ' ' || !(isascii (*++p) && isalpha (*p)))
{
- logmsg (L_ERR, "%s:%u: invalid input: %s",
+ logmsg (L_ERR, _("%s:%u: invalid input: %s"),
name, line, buf);
status = 1;
break;
}
var = p;
p = strchr (var, ' ');
if (!p)
{
- logmsg (L_ERR, "%s:%u: invalid input: %s",
+ logmsg (L_ERR, _("%s:%u: invalid input: %s"),
name, line, buf);
status = 1;
break;
}
*p++ = 0;
value = p;
@@ -520,23 +520,23 @@ read_symtab (pp_tab_t **tab, const char *name)
case 'n':
{
char *p;
double num = strtod (value, &p);
if (*p)
{
- logmsg (L_ERR, "%s:%u: invalid numeric value: %s",
+ logmsg (L_ERR, _("%s:%u: invalid numeric value: %s"),
name, line, value);
status = 1;
}
else
add_numeric_value (tab, var, num);
}
break;
default:
- logmsg (L_NOTICE, "%s:%u: ignoring unknown command %#03o",
+ logmsg (L_NOTICE, _("%s:%u: ignoring unknown command %#03o"),
name, line, cmd);
}
}
free (buf);
fclose (fp);

Return to:

Send suggestions and report system problems to the System administrator.