projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
src/ui/gui/psppire-dialog-action-runs.c (generate_syntax): Rename 'text' to 'str'
[pspp]
/
tests
/
data
/
datasheet-test.c
diff --git
a/tests/data/datasheet-test.c
b/tests/data/datasheet-test.c
index e3dad3b32c8a9b826656c38e32dc1a278cc91671..1310f51337234783e9ffd5b0752a87493c69da98 100644
(file)
--- a/
tests/data/datasheet-test.c
+++ b/
tests/data/datasheet-test.c
@@
-42,7
+42,6
@@
#include "error.h"
#include "minmax.h"
#include "progname.h"
#include "error.h"
#include "minmax.h"
#include "progname.h"
-#include "xalloc.h"
/* lazy_casereader callback function to instantiate a casereader
from the datasheet. */
/* lazy_casereader callback function to instantiate a casereader
from the datasheet. */
@@
-163,7
+162,7
@@
check_datasheet_casereader (struct mc *mc, struct casereader *reader,
"'%.*s' != '%.*s'",
row, col, n_rows, n_columns,
width, case_str_idx (c, col),
"'%.*s' != '%.*s'",
row, col, n_rows, n_columns,
width, case_str_idx (c, col),
- width,
value_str (&array[row][col], width)
);
+ width,
array[row][col].s
);
}
}
}
}
@@
-225,8
+224,8
@@
check_datasheet (struct mc *mc, struct datasheet *ds,
mc_error (mc, "element %zu,%zu (of %zu,%zu) differs: "
"'%.*s' != '%.*s'",
row, col, n_rows, n_columns,
mc_error (mc, "element %zu,%zu (of %zu,%zu) differs: "
"'%.*s' != '%.*s'",
row, col, n_rows, n_columns,
- width, v
alue_str (&v, width)
,
- width, v
alue_str (av, width)
);
+ width, v
.s
,
+ width, v
.s
);
difference = true;
}
value_destroy (&v, width);
difference = true;
}
value_destroy (&v, width);
@@
-249,7
+248,7
@@
check_datasheet (struct mc *mc, struct datasheet *ds,
if (width == 0)
ds_put_format (&s, " %g", v->f);
else
if (width == 0)
ds_put_format (&s, " %g", v->f);
else
- ds_put_format (&s, " '%.*s'", width, v
alue_str (v, width)
);
+ ds_put_format (&s, " '%.*s'", width, v
->s
);
}
mc_error (mc, "%s", ds_cstr (&s));
}
}
mc_error (mc, "%s", ds_cstr (&s));
}
@@
-270,8
+269,7
@@
check_datasheet (struct mc *mc, struct datasheet *ds,
if (width == 0)
ds_put_format (&s, " %g", v.f);
else
if (width == 0)
ds_put_format (&s, " %g", v.f);
else
- ds_put_format (&s, " '%.*s'",
- width, value_str (&v, width));
+ ds_put_format (&s, " '%.*s'", width, v.s);
}
mc_error (mc, "%s", ds_cstr (&s));
}
}
mc_error (mc, "%s", ds_cstr (&s));
}
@@
-407,12
+405,11
@@
value_from_param (union value *value, int width, unsigned int idx)
else
{
unsigned int hash = hash_int (idx, 0);
else
{
unsigned int hash = hash_int (idx, 0);
- uint8_t *string = value_str_rw (value, width);
int offset;
assert (width < 32);
for (offset = 0; offset < width; offset++)
int offset;
assert (width < 32);
for (offset = 0; offset < width; offset++)
-
string
[offset] = "ABCDEFGHIJ"[(hash >> offset) % 10];
+
value->s
[offset] = "ABCDEFGHIJ"[(hash >> offset) % 10];
}
}
}
}
@@
-858,10
+855,9
@@
usage (void)
" other values are string widths (0,1,11)\n",
program_name, program_name);
mc_options_usage ();
" other values are string widths (0,1,11)\n",
program_name, program_name);
mc_options_usage ();
- fputs ("\nOther options:\n"
- " --help Display this help message\n"
- "\nReport bugs to <bug-gnu-pspp@gnu.org>\n",
- stdout);
+ printf ("\nOther options:\n"
+ " --help Display this help message\n"
+ "\nReport bugs to <%s>\n", PACKAGE_BUGREPORT);
exit (0);
}
exit (0);
}