#include <errno.h>
#include <math.h>
#include "alloc.h"
+#include "case.h"
#include "file-handle.h"
#include "format.h"
#include "getline.h"
msg (VM (2), _("Read portable-file dictionary successfully."));
-#if DEBUGGING
- dump_dictionary (ext->dict);
-#endif
return ext->dict;
lossage:
return 0;
}
-/* Reads one case from portable file H into the value array PERM
+/* Reads one case from portable file H into PERM
according to the instuctions given in associated dictionary DICT,
which must have the get.fv elements appropriately set. Returns
nonzero only if successful. */
int
-pfm_read_case (struct file_handle *h, union value *perm, struct dictionary *dict)
+pfm_read_case (struct file_handle *h, struct ccase *perm,
+ struct dictionary *dict)
{
struct pfm_fhuser_ext *ext = h->ext;
continue;
if (v->type == NUMERIC)
- perm[v->fv].f = temp[v->get.fv].f;
+ case_data_rw (perm, v->fv)->f = temp[v->get.fv].f;
else
- memcpy (&perm[v->fv].s, &temp[v->get.fv], v->width);
+ memcpy (case_data_rw (perm, v->fv)->s, &temp[v->get.fv], v->width);
}
local_free (temp);