static gboolean psppire_data_store_data_in (PsppireDataStore *ds,
casenumber casenum, gint idx,
struct substring input,
- const struct fmt_spec *fmt);
+ struct fmt_spec);
static GObjectClass *parent_class = NULL;
const struct variable *variable = psppire_dict_get_variable (store->dict, col);
g_return_val_if_fail (variable, FALSE);
- const struct fmt_spec *fmt = var_get_print_format (variable);
+ struct fmt_spec fmt = var_get_print_format (variable);
int width = var_get_width (variable);
if (vp == NULL)
{
xx = data_in (ss_cstr (in), psppire_dict_encoding (store->dict),
- fmt->type, settings_get_fmt_settings (),
+ fmt.type, settings_get_fmt_settings (),
&val, width, "UTF-8");
}
var_is_value_missing (variable, val) == MV_SYSTEM)
return g_strdup ("");
- const struct fmt_spec *fmt = var_get_print_format (variable);
+ struct fmt_spec fmt = var_get_print_format (variable);
return value_to_text__ (*val, fmt, psppire_dict_encoding (store->dict));
}
const struct resize_datum_aux *aux = aux_;
int new_width = var_get_width (aux->new_variable);
const char *enc = dict_get_encoding (aux->dict);
- const struct fmt_spec *newfmt = var_get_print_format (aux->new_variable);
+ struct fmt_spec newfmt = var_get_print_format (aux->new_variable);
char *s = data_out (old, enc, var_get_print_format (aux->old_variable),
settings_get_fmt_settings ());
- enum fmt_type type = (fmt_usable_for_input (newfmt->type)
- ? newfmt->type
+ enum fmt_type type = (fmt_usable_for_input (newfmt.type)
+ ? newfmt.type
: FMT_DOLLAR);
free (data_in (ss_cstr (s), enc, type, settings_get_fmt_settings (),
new, new_width, enc));
/* Set the IDXth value of case C using D_IN */
static gboolean
psppire_data_store_data_in (PsppireDataStore *ds, casenumber casenum, gint idx,
- struct substring input, const struct fmt_spec *fmt)
+ struct substring input, struct fmt_spec fmt)
{
union value value;
int width;
FALSE);
value_init (&value, width);
ok = (datasheet_get_value (ds->datasheet, casenum, idx, &value)
- && data_in_msg (input, UTF8, fmt->type, settings_get_fmt_settings (),
+ && data_in_msg (input, UTF8, fmt.type, settings_get_fmt_settings (),
&value, width, dict_get_encoding (dict->dict))
&& datasheet_put_value (ds->datasheet, casenum, idx, &value));
value_destroy (&value, width);