pspp-cvs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Pspp-cvs] Changes to pspp/src/vfm.c


From: Ben Pfaff
Subject: [Pspp-cvs] Changes to pspp/src/vfm.c
Date: Tue, 26 Apr 2005 02:32:09 -0400

Index: pspp/src/vfm.c
diff -u pspp/src/vfm.c:1.32 pspp/src/vfm.c:1.33
--- pspp/src/vfm.c:1.32 Mon Mar 14 06:54:40 2005
+++ pspp/src/vfm.c      Tue Apr 26 06:32:02 2005
@@ -782,32 +782,9 @@
 static int
 equal_splits (const struct ccase *a, const struct ccase *b) 
 {
-  struct variable *const *split;
-  size_t split_cnt;
-  size_t i;
-    
-  split = dict_get_split_vars (default_dict);
-  split_cnt = dict_get_split_cnt (default_dict);
-  for (i = 0; i < split_cnt; i++)
-    {
-      struct variable *v = split[i];
-      
-      switch (v->type)
-       {
-       case NUMERIC:
-         if (case_num (a, v->fv) != case_num (b, v->fv))
-            return 0;
-         break;
-       case ALPHA:
-         if (memcmp (case_str (a, v->fv), case_str (b, v->fv), v->width))
-            return 0;
-         break;
-       default:
-         assert (0);
-       }
-    }
-
-  return 1;
+  return case_compare (a, b,
+                       dict_get_split_vars (default_dict),
+                       dict_get_split_cnt (default_dict)) == 0;
 }
 
 /* Dumps out the values of all the split variables for the case C. */




reply via email to

[Prev in Thread] Current Thread [Next in Thread]