Implement DATASET commands.
[pspp-builds.git] / src / language / data-io / save-translate.c
index 213f0bf735e40fe6b9ead6aac5aa66e3a1d698ad..f6487c57932e3faad8a64e45adcf570e9ab7b897 100644 (file)
 #include "data/casereader.h"
 #include "data/casewriter.h"
 #include "data/csv-file-writer.h"
+#include "data/dataset.h"
 #include "data/dictionary.h"
 #include "data/file-name.h"
 #include "data/format.h"
-#include "data/procedure.h"
 #include "data/settings.h"
 #include "language/command.h"
 #include "language/data-io/file-handle.h"
@@ -96,7 +96,7 @@ cmd_save_translate (struct lexer *lexer, struct dataset *ds)
 
          lex_match (lexer, T_EQUALS);
 
-         handle = fh_parse (lexer, FH_REF_FILE);
+         handle = fh_parse (lexer, FH_REF_FILE, NULL);
          if (handle == NULL)
            goto error;
        }
@@ -159,6 +159,7 @@ cmd_save_translate (struct lexer *lexer, struct dataset *ds)
                   lex_match (lexer, T_EQUALS);
                   if (!lex_force_string (lexer))
                     goto error;
+                  /* XXX should support multibyte UTF-8 delimiters */
                   if (ss_length (lex_tokss (lexer)) != 1)
                     {
                       msg (SE, _("The %s string must contain exactly one "
@@ -173,6 +174,7 @@ cmd_save_translate (struct lexer *lexer, struct dataset *ds)
                   lex_match (lexer, T_EQUALS);
                   if (!lex_force_string (lexer))
                     goto error;
+                  /* XXX should support multibyte UTF-8 qualifiers */
                   if (ss_length (lex_tokss (lexer)) != 1)
                     {
                       msg (SE, _("The %s string must contain exactly one "