First step in making struct variable opaque: the boring mechanical
[pspp-builds.git] / src / language / xforms / select-if.c
index 2543760be805de26f3a90e144ec4f77d3d95dc06..7d727e44e46ab3ba55ca0755841bf5ae2675c671 100644 (file)
@@ -112,13 +112,13 @@ cmd_filter (struct lexer *lexer, struct dataset *ds)
       if (!v)
        return CMD_FAILURE;
 
-      if (v->type == ALPHA)
+      if (var_is_alpha (v))
        {
          msg (SE, _("The filter variable must be numeric."));
          return CMD_FAILURE;
        }
 
-      if (dict_class_from_id (v->name) == DC_SCRATCH)
+      if (dict_class_from_id (var_get_name (v)) == DC_SCRATCH)
        {
          msg (SE, _("The filter variable may not be scratch."));
          return CMD_FAILURE;