search for: __hash__

Displaying 3 results from an estimated 3 matches for "__hash__".

Did you mean: __hash_
2009 Oct 12
0
What is the correct way to define __hash__?
On Mon, Oct 12, 2009 at 4:03 PM, Robert Kern <robert.kern at gmail.com> wrote: > On 2009-10-12 15:45 PM, Peng Yu wrote: >> >> Hi, >> >> I'm wondering what is the general way to define __hash__. I could add >> up all the members. But I am wondering if this would cause a >> performance issue for certain classes. > > Unless if you are very familiar with the math of hash functions, I don't > recommend that you try to implement one directly. Instead, make a tuple of &...
2009 Apr 19
4
[PATCH] btrfs: remove crc32c.h and use libcrc32c directly.
...lude "hash.h" -#include "crc32c.h" #include "ctree.h" #include "disk-io.h" #include "print-tree.h" diff --git a/fs/btrfs/hash.h b/fs/btrfs/hash.h index 2a020b2..db2ff97 100644 --- a/fs/btrfs/hash.h +++ b/fs/btrfs/hash.h @@ -19,9 +19,9 @@ #ifndef __HASH__ #define __HASH__ -#include "crc32c.h" +#include <linux/crc32c.h> static inline u64 btrfs_name_hash(const char *name, int len) { - return btrfs_crc32c((u32)~1, name, len); + return crc32c((u32)~1, name, len); } #endif -- 1.6.2.2 -- David Woodhouse...
2008 Aug 16
1
python how do i stem words in python?
...stemmer.__reduce_ex__ stemmer.__class__ stemmer.__repr__ stemmer.__delattr__ stemmer.__setattr__ stemmer.__dict__ stemmer.__str__ stemmer.__doc__ stemmer.__swig_destroy__ stemmer.__getattribute__ stemmer.__weakref__ stemmer.__hash__ stemmer.get_available_languages stemmer.__init__ stemmer.get_description stemmer.__module__ stemmer.this stemmer.__new__ stemmer.thisown stemmer.__reduce__