Add the WARN_UNUSED_RESULT attribute to all hash functions.
[pspp] / src / data / value.h
index 9205bc1a031feec0bee4d6858ca5af3b2e3d0b2e..299187285ad5843cd9fc9b549e053a9ebcfde769 100644 (file)
@@ -1,5 +1,5 @@
 /* PSPP - a program for statistical analysis.
-   Copyright (C) 1997-9, 2000, 2007, 2009, 2010 Free Software Foundation, Inc.
+   Copyright (C) 1997-9, 2000, 2007, 2009, 2010, 2012 Free Software Foundation, Inc.
 
    This program is free software: you can redistribute it and/or modify
    it under the terms of the GNU General Public License as published by
@@ -17,6 +17,7 @@
 #ifndef DATA_VALUE_H
 #define DATA_VALUE_H 1
 
+#include "libpspp/compiler.h"
 #include <assert.h>
 #include <stdbool.h>
 #include <stdlib.h>
@@ -71,12 +72,14 @@ void value_copy_buf_rpad (union value *dst, int dst_width,
 void value_set_missing (union value *, int width);
 int value_compare_3way (const union value *, const union value *, int width);
 bool value_equal (const union value *, const union value *, int width);
-unsigned int value_hash (const union value *, int width, unsigned int basis);
+unsigned int value_hash (const union value *, int width, unsigned int basis) WARN_UNUSED_RESULT;
 
 bool value_is_resizable (const union value *, int old_width, int new_width);
 bool value_needs_resize (int old_width, int new_width);
 void value_resize (union value *, int old_width, int new_width);
 
+bool value_is_spaces (const union value *, int width);
+
 static inline void value_swap (union value *, union value *);
 
 struct pool;