Apply patch #5225, assertions.
[pspp-builds.git] / src / data / format.c
index 88b613748c42e871733751a81b2ced6223e75d95..f4a61d34bc1efd0f18bcb89170740a44170892a9 100644 (file)
@@ -20,6 +20,7 @@
 #include <config.h>
 #include "format.h"
 #include <ctype.h>
+#include <libpspp/assertion.h>
 #include <libpspp/message.h>
 #include <stdlib.h>
 #include <libpspp/compiler.h>
@@ -280,7 +281,7 @@ convert_fmt_ItoO (const struct fmt_spec *input, struct fmt_spec *output)
     case FMT_CCC:
     case FMT_CCD:
     case FMT_CCE:
-      assert (0);
+      NOT_REACHED ();
     case FMT_Z:
     case FMT_A:
       /* nothing is necessary */
@@ -314,7 +315,7 @@ convert_fmt_ItoO (const struct fmt_spec *input, struct fmt_spec *output)
       /* nothing is necessary */
       break;
     default:
-      assert (0);
+      NOT_REACHED ();
     }
 
   assert (check_output_specifier (output, 0));
@@ -385,7 +386,6 @@ measure_is_valid(enum measure m)
 bool 
 alignment_is_valid(enum alignment a)
 {
-  if ( a < 0 ) return false;
   if ( a >= n_ALIGN) return false;
   return true;
 }