file = fn_open (file_name, "rb");
if (file == NULL)
{
- msg (ME, _("An error occurred while opening \"%s\": %s."),
+ msg (ME, _("An error occurred while opening `%s': %s."),
file_name, strerror (errno));
return IO_ERROR;
}
else if (result == YES)
return pfm_open_reader (handle, dict, NULL);
- msg (SE, _("\"%s\" is not a system or portable file."),
+ msg (SE, _("`%s' is not a system or portable file."),
fh_get_file_name (handle));
return NULL;
}
&w->file, NULL);
if (w->rf == NULL)
{
- msg (ME, _("Error opening \"%s\" for writing as a system file: %s."),
+ msg (ME, _("Error opening `%s' for writing as a system file: %s."),
fh_get_file_name (fh), strerror (errno));
goto error;
}
ok = false;
if (!ok)
- msg (ME, _("An I/O error occurred writing CSV file \"%s\"."),
+ msg (ME, _("An I/O error occurred writing CSV file `%s'."),
fh_get_file_name (w->fh));
if (ok ? !replace_file_commit (w->rf) : !replace_file_abort (w->rf))
if (ss_is_empty (i->input))
return true;
- data_warning (i, _("Trailing garbage \"%.*s\" following date."),
+ data_warning (i, _("Trailing garbage `%.*s' following date."),
(int) ss_length (i->input), ss_data (i->input));
return false;
}
char *handle_name;
struct file_handle *handle;
- handle_name = id != NULL ? xstrdup (id) : xasprintf ("\"%s\"", file_name);
+ handle_name = id != NULL ? xstrdup (id) : xasprintf ("`%s'", file_name);
handle = create_handle (id, handle_name, FH_REF_FILE);
handle->file_name = xstrdup (file_name);
handle->mode = properties->mode;
if ( NULL == gz)
{
- msg (ME, _("Error opening \"%s\" for reading as a Gnumeric file: %s."),
+ msg (ME, _("Error opening `%s' for reading as a Gnumeric file: %s."),
gri->file_name, strerror (errno));
goto error;
&r->start_col, &r->start_row,
&r->stop_col, &r->stop_row))
{
- msg (SE, _("Invalid cell range \"%s\""),
+ msg (SE, _("Invalid cell range `%s'"),
gri->cell_range);
goto error;
}
if ( n_var_specs == 0 )
{
- msg (MW, _("Selected sheet or range of spreadsheet \"%s\" is empty."),
+ msg (MW, _("Selected sheet or range of spreadsheet `%s' is empty."),
gri->file_name);
goto error;
}
{
if (fn_close (fh_get_file_name (r->fh), r->file) == EOF)
{
- msg (ME, _("Error closing portable file \"%s\": %s."),
+ msg (ME, _("Error closing portable file `%s': %s."),
fh_get_file_name (r->fh), strerror (errno));
r->ok = false;
}
r->file = fn_open (fh_get_file_name (r->fh), "rb");
if (r->file == NULL)
{
- msg (ME, _("An error occurred while opening \"%s\" for reading "
+ msg (ME, _("An error occurred while opening `%s' for reading "
"as a portable file: %s."),
fh_get_file_name (r->fh), strerror (errno));
goto error;
&w->file, NULL);
if (w->rf == NULL)
{
- msg (ME, _("Error opening \"%s\" for writing as a portable file: %s."),
+ msg (ME, _("Error opening `%s' for writing as a portable file: %s."),
fh_get_file_name (fh), strerror (errno));
goto error;
}
ok = false;
if (!ok)
- msg (ME, _("An I/O error occurred writing portable file \"%s\"."),
+ msg (ME, _("An I/O error occurred writing portable file `%s'."),
fh_get_file_name (w->fh));
if (ok ? !replace_file_commit (w->rf) : !replace_file_abort (w->rf))
r->file = fn_open (fh_get_file_name (fh), "rb");
if (r->file == NULL)
{
- msg (ME, _("Error opening \"%s\" for reading as a system file: %s."),
+ msg (ME, _("Error opening `%s' for reading as a system file: %s."),
fh_get_file_name (r->fh), strerror (errno));
goto error;
}
{
if (fn_close (fh_get_file_name (r->fh), r->file) == EOF)
{
- msg (ME, _("Error closing system file \"%s\": %s."),
+ msg (ME, _("Error closing system file `%s': %s."),
fh_get_file_name (r->fh), strerror (errno));
r->error = true;
}
if (!strcmp (number, "11"))
mrset->label_from_var_label = true;
else if (strcmp (number, "1"))
- sys_warn (r, _("Unexpected label source value \"%s\" "
+ sys_warn (r, _("Unexpected label source value `%s' "
"following 'E' at offset %zu in MRSETS record"),
number, text_pos (text));
}
sys_warn (r, _("Duplicate value label for %g on %s."),
label->value.f, var_get_name (v));
else
- sys_warn (r, _("Duplicate value label for \"%.*s\" on %s."),
+ sys_warn (r, _("Duplicate value label for `%.*s' on %s."),
max_width, value_str (&label->value, max_width),
var_get_name (v));
}
}
if (!skip && !var_add_value_label (v, &value, label))
- sys_warn (r, _("Duplicate value label for \"%.*s\" on %s."),
+ sys_warn (r, _("Duplicate value label for `%.*s' on %s."),
width, value_str (&value, width), var_get_name (v));
}
}
struct string text;
ds_init_empty (&text);
- ds_put_format (&text, "\"%s\" near offset 0x%llx: ",
+ ds_put_format (&text, "`%s' near offset 0x%llx: ",
fh_get_file_name (r->fh), (long long int) ftello (r->file));
ds_put_vformat (&text, format, args);
&w->file, NULL);
if (w->rf == NULL)
{
- msg (ME, _("Error opening \"%s\" for writing as a system file: %s."),
+ msg (ME, _("Error opening `%s' for writing as a system file: %s."),
fh_get_file_name (fh), strerror (errno));
goto error;
}
ok = false;
if (!ok)
- msg (ME, _("An I/O error occurred writing system file \"%s\"."),
+ msg (ME, _("An I/O error occurred writing system file `%s'."),
fh_get_file_name (w->fh));
if (ok ? !replace_file_commit (w->rf) : !replace_file_abort (w->rf))
if (!lex_force_id (lexer))
return false;
if (dict_lookup_var (dict, lex_tokid (lexer)))
- msg (SW, _("Dummy variable name \"%s\" hides dictionary "
- "variable \"%s\"."),
+ msg (SW, _("Dummy variable name `%s' hides dictionary "
+ "variable `%s'."),
lex_tokid (lexer), lex_tokid (lexer));
if (find_macro (block, ss_cstr (lex_tokid (lexer))))
{
- msg (SE, _("Dummy variable name \"%s\" is given twice."),
+ msg (SE, _("Dummy variable name `%s' is given twice."),
lex_tokid (lexer));
return false;
}
}
else if (block->loop_cnt != count)
{
- msg (SE, _("Dummy variable \"%.*s\" had %d "
- "substitutions, so \"%.*s\" must also, but %d "
+ msg (SE, _("Dummy variable `%.*s' had %d "
+ "substitutions, so `%.*s' must also, but %d "
"were specified."),
(int) ss_length (first_name), ss_data (first_name),
block->loop_cnt,
r->file = fn_open (fh_get_file_name (fh), "rb");
if (r->file == NULL)
{
- msg (ME, _("Could not open \"%s\" for reading as a data file: %s."),
+ msg (ME, _("Could not open `%s' for reading as a data file: %s."),
fh_get_file_name (r->fh), strerror (errno));
fh_unlock (r->lock);
fh_unref (fh);
&w->file, NULL);
if (w->rf == NULL)
{
- msg (ME, _("An error occurred while opening \"%s\" for writing "
+ msg (ME, _("An error occurred while opening `%s' for writing "
"as a data file: %s."),
fh_get_file_name (w->fh), strerror (errno));
dfm_close_writer (w);
ok = !dfm_write_error (w) && !fn_close (file_name, w->file);
if (!ok)
- msg (ME, _("I/O error occurred writing data file \"%s\"."), file_name);
+ msg (ME, _("I/O error occurred writing data file `%s'."), file_name);
if (ok ? !replace_file_commit (w->rf) : !replace_file_abort (w->rf))
ok = false;
}
else
{
- printf ("Unknown data file type \"\%s\"\n", lex_tokid (lexer));
goto error;
}
lex_get (lexer);
{
if (!fmt_from_name (type, &f.type))
{
- msg (SE, _("Unknown format type \"%s\"."), type);
+ msg (SE, _("Unknown format type `%s'."), type);
return false;
}
if (!fmt_check (&f, for_input))
switch (spec->type)
{
case PRT_LITERAL:
- tab_text_format (t, 0, row, TAB_LEFT | TAB_FIX, "\"%.*s\"",
+ tab_text_format (t, 0, row, TAB_LEFT | TAB_FIX, "`%.*s'",
(int) ds_length (&spec->string),
ds_data (&spec->string));
width = ds_length (&spec->string);
}
else if (!replace && fn_exists (fh_get_file_name (handle)))
{
- msg (SE, _("Output file \"%s\" exists but REPLACE was not specified."),
+ msg (SE, _("Output file `%s' exists but REPLACE was not specified."),
fh_get_file_name (handle));
goto error;
}
msg (SE, _("Cannot rename %s as %s because there already exists "
"a variable named %s. To rename variables with "
"overlapping names, use a single RENAME subcommand "
- "such as \"/RENAME (A=B)(B=C)(C=A)\", or equivalently, "
- "\"/RENAME (A B C=B C A)\"."),
+ "such as `/RENAME (A=B)(B=C)(C=A)', or equivalently, "
+ "`/RENAME (A B C=B C A)'."),
var_get_name (v), lex_tokid (lexer), lex_tokid (lexer));
return 0;
}
if (mrset->width == 0)
ds_put_format (&details, "%.0f\n", mrset->counted.f);
else
- ds_put_format (&details, "\"%.*s\"\n", mrset->width,
+ ds_put_format (&details, "`%.*s'\n", mrset->width,
value_str (&mrset->counted, mrset->width));
ds_put_format (&details, "%s: %s\n", _("Category label source"),
(mrset->cat_source == MRSET_VARLABELS
return true;
}
- msg (SE, _("Unrecognized date unit \"%.*s\". "
- "Valid date units are \"years\", \"quarters\", \"months\", "
- "\"weeks\", \"days\", \"hours\", \"minutes\", and \"seconds\"."),
+ /* TRANSLATORS: Don't translate the the actual unit names `weeks', `days' etc
+ They must remain in their original English. */
+ msg (SE, _("Unrecognized date unit `%.*s'. "
+ "Valid date units are `years', `quarters', `months', "
+ "`weeks', `days', `hours', `minutes', and `seconds'."),
(int) ss_length (name), ss_data (name));
return false;
}
else
{
msg (SE, _("Invalid DATESUM method. "
- "Valid choices are \"closest\" and \"rollover\"."));
+ "Valid choices are `closest' and `rollover'."));
return false;
}
}
parse_or (struct lexer *lexer, struct expression *e)
{
static const struct operator op =
- { T_OR, OP_OR, "logical disjunction (\"OR\")" };
+ { T_OR, OP_OR, "logical disjunction (`OR')" };
return parse_binary_operators (lexer, e, parse_and (lexer, e), &op, 1, parse_and, NULL);
}
parse_and (struct lexer *lexer, struct expression *e)
{
static const struct operator op =
- { T_AND, OP_AND, "logical conjunction (\"AND\")" };
+ { T_AND, OP_AND, "logical conjunction (`AND')" };
return parse_binary_operators (lexer, e, parse_not (lexer, e),
&op, 1, parse_not, NULL);
parse_not (struct lexer *lexer, struct expression *e)
{
static const struct operator op
- = { T_NOT, OP_NOT, "logical negation (\"NOT\")" };
+ = { T_NOT, OP_NOT, "logical negation (`NOT')" };
return parse_inverting_unary_operator (lexer, e, &op, parse_rel);
}
parse_rel (struct lexer *lexer, struct expression *e)
{
const char *chain_warning =
- _("Chaining relational operators (e.g. \"a < b < c\") will "
+ _("Chaining relational operators (e.g. `a < b < c') will "
"not produce the mathematically expected result. "
"Use the AND logical operator to fix the problem "
- "(e.g. \"a < b AND b < c\"). "
+ "(e.g. `a < b AND b < c'). "
"If chaining is really intended, parentheses will disable "
- "this warning (e.g. \"(a < b) < c\".)");
+ "this warning (e.g. `(a < b) < c'.)");
union any_node *node = parse_add (lexer, e);
{
static const struct operator ops[] =
{
- { '=', OP_EQ, "numeric equality (\"=\")" },
- { T_EQ, OP_EQ, "numeric equality (\"EQ\")" },
- { T_GE, OP_GE, "numeric greater-than-or-equal-to (\">=\")" },
- { T_GT, OP_GT, "numeric greater than (\">\")" },
- { T_LE, OP_LE, "numeric less-than-or-equal-to (\"<=\")" },
- { T_LT, OP_LT, "numeric less than (\"<\")" },
- { T_NE, OP_NE, "numeric inequality (\"<>\")" },
+ { '=', OP_EQ, "numeric equality (`=')" },
+ { T_EQ, OP_EQ, "numeric equality (`EQ')" },
+ { T_GE, OP_GE, "numeric greater-than-or-equal-to (`>=')" },
+ { T_GT, OP_GT, "numeric greater than (`>')" },
+ { T_LE, OP_LE, "numeric less-than-or-equal-to (`<=')" },
+ { T_LT, OP_LT, "numeric less than (`<')" },
+ { T_NE, OP_NE, "numeric inequality (`<>')" },
};
return parse_binary_operators (lexer, e, node, ops,
{
static const struct operator ops[] =
{
- { '=', OP_EQ_STRING, "string equality (\"=\")" },
- { T_EQ, OP_EQ_STRING, "string equality (\"EQ\")" },
- { T_GE, OP_GE_STRING, "string greater-than-or-equal-to (\">=\")" },
- { T_GT, OP_GT_STRING, "string greater than (\">\")" },
- { T_LE, OP_LE_STRING, "string less-than-or-equal-to (\"<=\")" },
- { T_LT, OP_LT_STRING, "string less than (\"<\")" },
- { T_NE, OP_NE_STRING, "string inequality (\"<>\")" },
+ { '=', OP_EQ_STRING, "string equality (`=')" },
+ { T_EQ, OP_EQ_STRING, "string equality (`EQ')" },
+ { T_GE, OP_GE_STRING, "string greater-than-or-equal-to (`>=')" },
+ { T_GT, OP_GT_STRING, "string greater than (`>')" },
+ { T_LE, OP_LE_STRING, "string less-than-or-equal-to (`<=')" },
+ { T_LT, OP_LT_STRING, "string less than (`<')" },
+ { T_NE, OP_NE_STRING, "string inequality (`<>')" },
};
return parse_binary_operators (lexer, e, node, ops,
{
static const struct operator ops[] =
{
- { '+', OP_ADD, "addition (\"+\")" },
- { '-', OP_SUB, "subtraction (\"-\")" },
+ { '+', OP_ADD, "addition (`+')" },
+ { '-', OP_SUB, "subtraction (`-')" },
};
return parse_binary_operators (lexer, e, parse_mul (lexer, e),
{
static const struct operator ops[] =
{
- { '*', OP_MUL, "multiplication (\"*\")" },
- { '/', OP_DIV, "division (\"/\")" },
+ { '*', OP_MUL, "multiplication (`*')" },
+ { '/', OP_DIV, "division (`/')" },
};
return parse_binary_operators (lexer, e, parse_neg (lexer, e),
static union any_node *
parse_neg (struct lexer *lexer, struct expression *e)
{
- static const struct operator op = { '-', OP_NEG, "negation (\"-\")" };
+ static const struct operator op = { '-', OP_NEG, "negation (`-')" };
return parse_inverting_unary_operator (lexer, e, &op, parse_exp);
}
parse_exp (struct lexer *lexer, struct expression *e)
{
static const struct operator op =
- { T_EXP, OP_POW, "exponentiation (\"**\")" };
+ { T_EXP, OP_POW, "exponentiation (`**')" };
const char *chain_warning =
- _("The exponentiation operator (\"**\") is left-associative, "
+ _("The exponentiation operator (`**') is left-associative, "
"even though right-associative semantics are more useful. "
- "That is, \"a**b**c\" equals \"(a**b)**c\", not as \"a**(b**c)\". "
+ "That is, `a**b**c' equals `(a**b)**c', not as `a**(b**c)'. "
"To disable this warning, insert parentheses.");
return parse_binary_operators (lexer, e, parse_primary (lexer, e), &op, 1,
if (!fmt_from_name (type, &format->type))
{
- msg (SE, _("Unknown format type \"%s\"."), type);
+ msg (SE, _("Unknown format type `%s'."), type);
return false;
}
}
if (!fmt_from_name (ds_cstr (lex_tokstr (lexer)), type))
{
- msg (SE, _("Unknown format type \"%s\"."), ds_cstr (lex_tokstr (lexer)));
+ msg (SE, _("Unknown format type `%s'."), ds_cstr (lex_tokstr (lexer)));
return false;
}
lex_get (lexer);
break;
case T_STRING:
- fprintf (stderr, "STRING\t\"%s\"\n", ds_cstr (&lexer->tokstr));
+ fprintf (stderr, "STRING\t`%s'\n", ds_cstr (&lexer->tokstr));
break;
case T_STOP:
static char *
show_decimals (const struct dataset *ds UNUSED)
{
- return xasprintf ("\"%c\"", settings_get_decimal_char (FMT_F));
+ return xasprintf ("`%c'", settings_get_decimal_char (FMT_F));
}
static char *
show_endcmd (const struct dataset *ds UNUSED)
{
- return xasprintf ("\"%c\"", settings_get_endcmd ());
+ return xasprintf ("`%c'", settings_get_endcmd ());
}
static char *
const int err = errno;
fprintf (stderr,
"Warning: "
- "cannot create a converter for \"%s\" to \"%s\": %s\n",
+ "cannot create a converter for `%s' to `%s': %s\n",
fromcode, tocode, strerror (err));
}
mc_options_set_strategy (options, MC_RANDOM);
else
error (1, 0,
- "strategy must be \"broad\", \"deep\", or \"random\"");
+ "strategy must be `broad', `deep', or `random'");
break;
case OPT_MAX_DEPTH:
else if (!strcmp (optarg, "random"))
mc_options_set_queue_limit_strategy (options, MC_DROP_RANDOM);
else
- error (1, 0, "--queue-drop argument must be \"newest\", "
- "\"oldest\", or \"random\"");
+ error (1, 0, "--queue-drop argument must be `newest' "
+ "`oldest' or `random'");
break;
case OPT_SEED:
ascii_close_page (a);
if (fn_close (a->file_name, a->file) != 0)
- error (0, errno, _("ascii: closing output file \"%s\""),
+ error (0, errno, _("ascii: closing output file `%s'"),
a->file_name);
a->file = NULL;
}
}
else
{
- error (0, errno, _("ascii: opening output file \"%s\""),
+ error (0, errno, _("ascii: opening output file `%s'"),
a->file_name);
a->error = true;
return false;
desc = pango_font_description_from_string (string);
if (desc == NULL)
{
- error (0, 0, _("\"%s\": bad font specification"), string);
+ error (0, 0, _("`%s': bad font specification"), string);
/* Fall back to DEFAULT_VALUE, which had better be a valid font
description. */
status = cairo_surface_status (surface);
if (status != CAIRO_STATUS_SUCCESS)
{
- error (0, 0, _("error opening output file \"%s\": %s"),
+ error (0, 0, _("error opening output file `%s': %s"),
file_name, cairo_status_to_string (status));
cairo_surface_destroy (surface);
goto error;
status = cairo_surface_write_to_png (surface, file_name);
if (status != CAIRO_STATUS_SUCCESS)
- error (0, 0, _("error writing output file \"%s\": %s"),
+ error (0, 0, _("error writing output file `%s': %s"),
file_name, cairo_status_to_string (status));
cairo_destroy (cr);
if (csv->file == NULL)
{
- error (0, errno, _("error opening output file \"%s\""), csv->file_name);
+ error (0, errno, _("error opening output file `%s'"), csv->file_name);
output_driver_destroy (d);
return NULL;
}
device_type = SETTINGS_DEVICE_LISTING;
else
{
+ /* TRANSLATORS: Don't translate the words `terminal' or `listing'. */
error (0, 0, _("%s is not a valid device type (the choices are "
- "\"terminal\" and \"listing\")"), device_string);
+ "`terminal' and `listing')"), device_string);
device_type = default_device_type (file_name);
}
const char *key;
STRING_MAP_FOR_EACH_KEY (key, node, options)
- error (0, 0, _("%s: unknown option \"%s\""), file_name, key);
+ error (0, 0, _("%s: unknown option `%s'"), file_name, key);
}
string_map_clear (options);
html->file = fn_open (html->file_name, "w");
if (html->file == NULL)
{
- error (0, errno, _("error opening output file \"%s\""), html->file_name);
+ error (0, errno, _("error opening output file `%s'"), html->file_name);
goto error;
}
fputs ("<HTML>\n", html->file);
fputs ("<HEAD>\n", html->file);
print_title_tag (html->file, "TITLE", _("PSPP Output"));
- fprintf (html->file, "<META NAME=\"generator\" CONTENT=\"%s\">\n", version);
+ fprintf (html->file, "<META NAME=\"generator\" CONTENT=`%s'>\n", version);
fputs ("<META http-equiv=\"Content-Style-Type\" content=\"text/css\">\n",
html->file);
fputs ("<META HTTP-EQUIV=\"Content-Type\" "
html->chart_cnt++);
if (file_name != NULL)
{
- fprintf (html->file, "<IMG SRC=\"%s\"/>", file_name);
+ fprintf (html->file, "<IMG SRC=`%s'/>", file_name);
free (file_name);
}
}
if (journal != NULL && journal->file != NULL)
{
if (fwriteerror (journal->file))
- error (0, errno, _("error writing output file \"%s\""),
+ error (0, errno, _("error writing output file `%s'"),
journal_file_name);
journal->file = NULL;
}
j->file = fopen (journal_file_name, "a");
if (j->file == NULL)
{
- error (0, errno, _("error opening output file \"%s\""),
+ error (0, errno, _("error opening output file `%s'"),
journal_file_name);
output_driver_destroy (&j->driver);
return;
file = fopen (file_name, "r");
if (file == NULL)
{
- error (0, errno, _("error opening input file \"%s\""), file_name);
+ error (0, errno, _("error opening input file `%s'"), file_name);
return false;
}
if (!ds_read_config_line (&line, &line_number, file))
{
if (ferror (file))
- error (0, errno, _("error reading file \"%s\""), file_name);
+ error (0, errno, _("error reading file `%s'"), file_name);
break;
}
fclose (file);
ds_destroy (&line);
- error (0, 0, _("paper size file \"%s\" does not state a paper size"),
+ error (0, 0, _("paper size file `%s' does not state a paper size"),
file_name);
return false;
}
file = fn_open (file_name, "w");
if (file == NULL)
{
- error (0, errno, _("error opening output file \"%s\""), file_name);
+ error (0, errno, _("error opening output file `%s'"), file_name);
return NULL;
}
return false;
else
{
- error (0, 0, _("%s: \"%s\" is \"%s\" but a Boolean value is required"),
+ error (0, 0, _("%s: `%s' is `%s' but a Boolean value is required"),
driver_name, value, key);
return -1;
}
ds_put_format (&choices, "`%s'", s);
}
- error (0, 0, _("%s: \"%s\" is \"%s\" but one of the following "
+ error (0, 0, _("%s: `%s' is `%s' but one of the following "
"is required: %s"),
o->driver_name, o->name, o->value, ds_cstr (&choices));
ds_destroy (&choices);
else if (max_value == INT_MAX)
{
if (min_value == 0)
- error (0, 0, _("%s: \"%s\" is \"%s\" but a nonnegative integer "
+ error (0, 0, _("%s: `%s' is `%s' but a nonnegative integer "
"is required"),
o->driver_name, o->name, o->value);
else if (min_value == 1)
- error (0, 0, _("%s: \"%s\" is \"%s\" but a positive integer is "
+ error (0, 0, _("%s: `%s' is `%s' but a positive integer is "
"required"), o->driver_name, o->name, o->value);
else if (min_value == INT_MIN)
- error (0, 0, _("%s: \"%s\" is \"%s\" but an integer is required"),
+ error (0, 0, _("%s: `%s' is `%s' but an integer is required"),
o->driver_name, o->name, o->value);
else
- error (0, 0, _("%s: \"%s\" is \"%s\" but an integer greater "
+ error (0, 0, _("%s: `%s' is `%s' but an integer greater "
"than %d is required"),
o->driver_name, o->name, o->value, min_value - 1);
}
else
- error (0, 0, _("%s: \"%s\" is \"%s\" but an integer between %d and "
+ error (0, 0, _("%s: `%s' is `%s' but an integer between %d and "
"%d is required"),
o->driver_name, o->name, o->value, min_value, max_value);
}
chart_file_name = xstrdup (o->value);
else
{
- error (0, 0, _("%s: \"%s\" is \"%s\" but a file name that contains "
- "\"#\" is required."),
+ error (0, 0, _("%s: `%s' is `%s' but a file name that contains "
+ "`#' is required."),
o->name, o->value, o->driver_name);
chart_file_name = default_chart_file_name (o->default_value);
}
o = gtk_builder_get_object (builder, name);
if ( !o )
- g_critical ("Object \"%s\" could not be found\n", name);
+ g_critical ("Object `%s' could not be found\n", name);
else if ( ! g_type_is_a (G_OBJECT_TYPE (o), type))
{
- g_critical ("Object \"%s\" was expected to have type %s, but in fact has type %s",
+ g_critical ("Object `%s' was expected to have type %s, but in fact has type %s",
name, g_type_name (type), G_OBJECT_TYPE_NAME (o));
}
{
const struct variable *v = psppire_dict_get_variable (dict, i);
int di = var_get_dict_index (v);
- g_print ("\"%s\" idx=%d, fv=%d\n",
+ g_print ("`%s' idx=%d, fv=%d\n",
var_get_name(v),
di,
var_get_case_index(v));
if ( result )
{
char *fn = g_filename_display_name (filename);
- gchar *msg = g_strdup_printf (_("Saved file \"%s\""), fn);
+ gchar *msg = g_strdup_printf (_("Saved file `%s'"), fn);
g_free (fn);
gtk_statusbar_push (GTK_STATUSBAR (se->sb), se->text_context, msg);
gtk_text_buffer_set_modified (buffer, FALSE);
psppire_var_store_init (PsppireVarStore *var_store)
{
if ( ! gdk_color_parse (DISABLED_COLOR, &var_store->disabled))
- g_critical ("Could not parse color \"%s\"", DISABLED_COLOR);
+ g_critical ("Could not parse color `%s'", DISABLED_COLOR);
var_store->dictionary = NULL;
var_store->format_type = PSPPIRE_VAR_STORE_OUTPUT_FORMATS;
default:
{
char str[FMT_STRING_LEN_MAX + 1];
- g_warning ("Unknown format: \"%s\"\n",
+ g_warning ("Unknown format: `%s'\n",
fmt_to_string (write_spec, str));
}
break;
{
gchar *const vstr = value_to_text (vl->value, dict, *write_spec);
- return g_strdup_printf ( "{%s,\"%s\"}_", vstr, val_lab_get_label (vl));
+ return g_strdup_printf ( "{%s,`%s'}_", vstr, val_lab_get_label (vl));
}
}
}
if ( G_VALUE_TYPE (&value) == PSPPIRE_VAR_PTR_TYPE)
var = g_value_get_boxed (&value);
else
- g_critical ("Unsupported type \"%s\", in variable name treeview.",
+ g_critical ("Unsupported type `%s', in variable name treeview.",
G_VALUE_TYPE_NAME (&value));
g_value_unset (&value);
GTK_DIALOG_MODAL,
GTK_MESSAGE_WARNING,
GTK_BUTTONS_NONE,
- _("Save the changes to \"%s\" before closing?"),
+ _("Save the changes to `%s' before closing?"),
fn);
g_free (fn);
utf8 = g_locale_to_utf8 (arg, -1, NULL, &written, &err);
if ( NULL == utf8)
{
- g_warning ("Cannot convert filename from local encoding \"%s\" to UTF-8: %s",
+ g_warning ("Cannot convert filename from local encoding `%s' to UTF-8: %s",
local_encoding,
err->message);
g_clear_error (&err);
stream = fopen (file->file_name, "r");
if (stream == NULL)
{
- msg (ME, _("Could not open \"%s\": %s"),
+ msg (ME, _("Could not open `%s': %s"),
file->file_name, strerror (errno));
return false;
}
if (feof (stream))
break;
else if (ferror (stream))
- msg (ME, _("Error reading \"%s\": %s"),
+ msg (ME, _("Error reading `%s': %s"),
file->file_name, strerror (errno));
else
- msg (ME, _("Failed to read \"%s\", because it contains a line "
+ msg (ME, _("Failed to read `%s', because it contains a line "
"over %d bytes long and therefore appears not to be "
"a text file."),
file->file_name, MAX_LINE_LEN);
if (file->line_cnt == 0)
{
- msg (ME, _("\"%s\" is empty."), file->file_name);
+ msg (ME, _("`%s' is empty."), file->file_name);
fclose (stream);
destroy_file (ia);
return false;
{
char fmt_string[FMT_STRING_LEN_MAX + 1];
fmt_to_string (in, fmt_string);
- tooltip = xasprintf (_("Field content \"%.*s\" cannot be parsed in "
+ tooltip = xasprintf (_("Field content `%.*s' cannot be parsed in "
"format %s."),
(int) field.length, field.string,
fmt_string);
value_to_text (vl->value, dialog->dict,
*var_get_write_format (dialog->pv));
- gchar *const text = g_strdup_printf ("%s = \"%s\"",
+ gchar *const text = g_strdup_printf ("%s = `%s'",
vstr, val_lab_get_label (vl));
gtk_list_store_append (list_store, &iter);
else if (!strcmp (optarg, "enhanced"))
settings_set_algorithm (ENHANCED);
else
+ /* TRANSLATORS: Leave the words `compatible' and `enhanced' in their
+ original English. */
error (1, 0,
- _("Algorithm must be either \"compatible\" or \"enhanced\"."));
+ _("Algorithm must be either `compatible' or `enhanced'."));
break;
case OPT_INCLUDE:
else if (!strcmp (optarg, "enhanced"))
settings_set_syntax (ENHANCED);
else
+ /* TRANSLATORS: Leave the words `compatible' and `enhanced' in their
+ original English. */
error (1, 0,
- _("Syntax must be either \"compatible\" or \"enhanced\"."));
+ _("Syntax must be either `compatible' or `enhanced'."));
break;
default:
activity="compare output 2"
diff -c $TEMPDIR/pspp.csv - <<EOF
-"warning: Selected sheet or range of spreadsheet ""$TEMPDIR/Book1.gnumeric"" is empty."
+warning: Selected sheet or range of spreadsheet \`$TEMPDIR/Book1.gnumeric' is empty.
-"warning: Selected sheet or range of spreadsheet ""$TEMPDIR/Book1.gnumeric"" is empty."
+warning: Selected sheet or range of spreadsheet \`$TEMPDIR/Book1.gnumeric' is empty.
EOF
if [ $? -ne 0 ] ; then fail ; fi
activity="compare results"
diff -c $TEMPDIR/pspp.csv - <<EOF
-"Table: Reading 1 record from ""$top_srcdir/tests/weighting.data""."
+Table: Reading 1 record from \`$top_srcdir/tests/weighting.data'.
Variable,Record,Columns,Format
AVAR,1,1- 5,F5.0
BVAR,1,6- 10,F5.0
activity="compare results"
diff -c $TEMPDIR/pspp.csv - <<EOF
-"Table: Reading 1 record from ""$top_srcdir/tests/weighting.data""."
+Table: Reading 1 record from \`$top_srcdir/tests/weighting.data'.
Variable,Record,Columns,Format
AVAR,1,1- 5,F5.0
BVAR,1,6- 10,F5.0
r.file_name = argv[i];
r.file = fopen (r.file_name, "rb");
if (r.file == NULL)
- error (EXIT_FAILURE, errno, "error opening \"%s\"", r.file_name);
+ error (EXIT_FAILURE, errno, "error opening `%s'", r.file_name);
r.n_variable_records = 0;
r.n_variables = 0;
r.n_var_widths = 0;
if (!strcmp (number, "11"))
label_from_var_label = true;
else if (strcmp (number, "1"))
- sys_warn (r, _("Unexpected label source value \"%s\" "
+ sys_warn (r, _("Unexpected label source value `%s' "
"following 'E' at offset %zu in MRSETS record"),
number, text_pos (text));
c
d
","Multiple dichotomy set
-Counted value: ""c""
+Counted value: `c'
Category label source: Variable labels
"
$e,"w
c
d
","Multiple dichotomy set
-Counted value: ""c""
+Counted value: `c'
Category label source: Variable labels
"
$e,"w
[[1 OR $false], [true]],
[[1 OR $sysmis], [true]],
[[2 OR $sysmis], [sysmis],
- [error: DEBUG EVALUATE: An operand of the logical disjunction ("OR") operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
+ [error: DEBUG EVALUATE: An operand of the logical disjunction (`OR') operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
[[2 AND $sysmis], [false],
- [error: DEBUG EVALUATE: An operand of the logical conjunction ("AND") operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
+ [error: DEBUG EVALUATE: An operand of the logical conjunction (`AND') operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
[['string' AND $sysmis], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying logical conjunction ("AND") operator: cannot convert string to boolean.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying logical conjunction (`AND') operator: cannot convert string to boolean.]],
[[0 AND $sysmis], [false]],
[[(1>2) + 1], [1.00]],
[[$true + $false], [1.00]])
[[$sysmis + 1], [sysmis]],
[[7676 + $sysmis], [sysmis]],
[[('foo') + 5], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying addition ("+") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying addition (`+') operator: cannot convert string to number.]],
dnl Arithmetic concatenation requires CONCAT:
[[('foo') + ('bar')], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying addition ("+") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying addition (`+') operator: cannot convert string to number.]],
dnl Lexical concatenation succeeds:
[['foo' + 'bar'], ["foobar"]],
[[1 +3 - 2 +4 -5], [1.00]],
[[1 - $true], [0.00]],
[[$true - 4/3], [-0.33]],
[['string' - 1e10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying subtraction ("-") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying subtraction (`-') operator: cannot convert string to number.]],
[[9.5 - ''], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying subtraction ("-") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying subtraction (`-') operator: cannot convert string to number.]],
[[1 - 2], [-1.00]],
[[52 -23], [29.00]])
[[2**8], [256.00]],
[[(2**3)**4], [4096.00]],
[[2**3**4], [4096.00],
- [warning: DEBUG EVALUATE: The exponentiation operator ("**") is left-associative, even though right-associative semantics are more useful. That is, "a**b**c" equals "(a**b)**c", not as "a**(b**c)". To disable this warning, insert parentheses.]])
+ [warning: DEBUG EVALUATE: The exponentiation operator (`**') is left-associative, even though right-associative semantics are more useful. That is, `a**b**c' equals `(a**b)**c', not as `a**(b**c)'. To disable this warning, insert parentheses.]])
CHECK_EXPR_EVAL([unary minus],
[[2+-3], [-1.00]],
[[not $false], [true]],
[[not 0], [true]],
[[not 2.5], [true],
- [error: DEBUG EVALUATE: An operand of the logical negation ("NOT") operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
+ [error: DEBUG EVALUATE: An operand of the logical negation (`NOT') operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
[[not $true], [false]],
[[not 1], [false]],
[[not $sysmis], [sysmis]],
[[~ $false], [true]],
[[~ 0], [true]],
[[~ 2.5], [true],
- [error: DEBUG EVALUATE: An operand of the logical negation ("NOT") operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
+ [error: DEBUG EVALUATE: An operand of the logical negation (`NOT') operator was found to have a value other than 0 (false), 1 (true), or the system-missing value. The result was forced to 0.]],
[[~ $true], [false]],
[[~ 1], [false]],
[[~ $sysmis], [sysmis]])
[[1 eq 2], [false]],
[[2 = 3], [false]],
[[1 eq 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric equality ("EQ") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric equality (`EQ') operator: cannot convert string to number.]],
[[5 eq 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric equality ("EQ") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric equality (`EQ') operator: cannot convert string to number.]],
[['baz' = 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string equality ("=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string equality (`=') operator: cannot convert number to string.]],
[['quux' = 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string equality ("=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string equality (`=') operator: cannot convert number to string.]],
[['foobar' = 'foobar'], [true]],
[['quux' = 'bar'], [false]],
[['bar ' = 'bar'], [true]],
dnl Check precedence:
[[1 + 2 = 3], [true]],
[[1 >= 2 = 2 ge 3], [false],
- [warning: DEBUG EVALUATE: Chaining relational operators (e.g. "a < b < c") will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. "a < b AND b < c"). If chaining is really intended, parentheses will disable this warning (e.g. "(a < b) < c".)]],
+ [warning: DEBUG EVALUATE: Chaining relational operators (e.g. `a < b < c') will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. `a < b AND b < c'). If chaining is really intended, parentheses will disable this warning (e.g. `(a < b) < c'.)]],
dnl Mathematically true:
[[3 ne 2 ~= 1], [false],
- [warning: DEBUG EVALUATE: Chaining relational operators (e.g. "a < b < c") will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. "a < b AND b < c"). If chaining is really intended, parentheses will disable this warning (e.g. "(a < b) < c".)]],
+ [warning: DEBUG EVALUATE: Chaining relational operators (e.g. `a < b < c') will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. `a < b AND b < c'). If chaining is really intended, parentheses will disable this warning (e.g. `(a < b) < c'.)]],
[[3 > 2 > 1], [false],
- [warning: DEBUG EVALUATE: Chaining relational operators (e.g. "a < b < c") will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. "a < b AND b < c"). If chaining is really intended, parentheses will disable this warning (e.g. "(a < b) < c".)]],
+ [warning: DEBUG EVALUATE: Chaining relational operators (e.g. `a < b < c') will not produce the mathematically expected result. Use the AND logical operator to fix the problem (e.g. `a < b AND b < c'). If chaining is really intended, parentheses will disable this warning (e.g. `(a < b) < c'.)]],
[[1 <= 2], [true]],
[[2.5 <= 1.5], [false]],
[[2 < = 2], [error],
[error: DEBUG EVALUATE: Syntax error in expression at `='.]],
[[1 <= 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric less-than-or-equal-to ("<=") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric less-than-or-equal-to (`<=') operator: cannot convert string to number.]],
[[5 <= 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric less-than-or-equal-to ("<=") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric less-than-or-equal-to (`<=') operator: cannot convert string to number.]],
[['baz' <= 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string less-than-or-equal-to ("<=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string less-than-or-equal-to (`<=') operator: cannot convert number to string.]],
[['quux' <= 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string less-than-or-equal-to ("<=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string less-than-or-equal-to (`<=') operator: cannot convert number to string.]],
[['0123' <= '0123'], [true]],
[['0123' <= '0124'], [true]],
[['0124' le '0123'], [false]],
[[3.5 lt 4], [true]],
[[4 lt 3.5], [false]],
[[1 lt 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric less than ("<") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric less than (`<') operator: cannot convert string to number.]],
[[5 lt 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric less than ("<") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric less than (`<') operator: cannot convert string to number.]],
[['baz' < 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string less than ("<") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string less than (`<') operator: cannot convert number to string.]],
[['quux' < 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string less than ("<") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string less than (`<') operator: cannot convert number to string.]],
[['0123' lt '0123'], [false]],
[['0123' < '0124'], [true]],
[['0124' lt '0123'], [false]],
[[2 > = 2], [error],
[error: DEBUG EVALUATE: Syntax error in expression at `='.]],
[[1 >= 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric greater-than-or-equal-to (">=") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric greater-than-or-equal-to (`>=') operator: cannot convert string to number.]],
[[5 ge 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric greater-than-or-equal-to (">=") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric greater-than-or-equal-to (`>=') operator: cannot convert string to number.]],
[['baz' ge 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string greater-than-or-equal-to (">=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string greater-than-or-equal-to (`>=') operator: cannot convert number to string.]],
[['quux' >= 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string greater-than-or-equal-to (">=") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string greater-than-or-equal-to (`>=') operator: cannot convert number to string.]],
[['0123' ge '0123'], [true]],
[['0123' >= '0124'], [false]],
[['0124' >= '0123'], [true]],
[[3.5 gt 4], [false]],
[[4 gt 3.5], [true]],
[[1 gt 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric greater than (">") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric greater than (`>') operator: cannot convert string to number.]],
[[5 gt 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric greater than (">") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric greater than (`>') operator: cannot convert string to number.]],
[['baz' > 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string greater than (">") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string greater than (`>') operator: cannot convert number to string.]],
[['quux' > 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string greater than (">") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string greater than (`>') operator: cannot convert number to string.]],
[['0123' gt '0123'], [false]],
[['0123' > '0124'], [false]],
[['0124' gt '0123'], [true]],
[[1 <> 2], [true]],
[[2 ne 3], [true]],
[[1 ~= 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric inequality ("<>") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric inequality (`<>') operator: cannot convert string to number.]],
[[5 <> 'foobar'], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying numeric inequality ("<>") operator: cannot convert string to number.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying numeric inequality (`<>') operator: cannot convert string to number.]],
[['baz' ne 10], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string inequality ("<>") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string inequality (`<>') operator: cannot convert number to string.]],
[['quux' ~= 5.55], [error],
- [error: DEBUG EVALUATE: Type mismatch while applying string inequality ("<>") operator: cannot convert number to string.]],
+ [error: DEBUG EVALUATE: Type mismatch while applying string inequality (`<>') operator: cannot convert number to string.]],
[['foobar' <> 'foobar'], [false]],
[['quux' ne 'bar'], [true]],
[['bar ' <> 'bar'], [false]],
print $PSPP::errstr, "\n";
]])
AT_CHECK([RUN_PERL_MODULE test.pl], [0],
- [[Error opening "no-such-file.sav" for reading as a system file: No such file or directory.
+ [[Error opening `no-such-file.sav' for reading as a system file: No such file or directory.
]],
[[Name "PSPP::errstr" used only once: possible typo at test.pl line 8.
]])