Skip to content

Commit

Permalink
Remove FNV cbits
Browse files Browse the repository at this point in the history
  • Loading branch information
phadej committed May 18, 2024
1 parent 3ebcb47 commit b88e9b3
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 73 deletions.
56 changes: 0 additions & 56 deletions cbits/fnv.c

This file was deleted.

1 change: 0 additions & 1 deletion hashable.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ library
Data.Hashable.LowLevel
Data.Hashable.Mix

c-sources: cbits/fnv.c
include-dirs: include
hs-source-dirs: src
build-depends:
Expand Down
16 changes: 0 additions & 16 deletions include/HsHashable.h
Original file line number Diff line number Diff line change
@@ -1,22 +1,6 @@
#ifndef HS_HASHABLE_H
#define HS_HASHABLE_H

#include "MachDeps.h"
#include <stdint.h>

#if WORD_SIZE_IN_BITS == 64
#define FNV_PRIME 1099511628211
#define FNV_SIGNED int64_t
#define FNV_UNSIGNED uint64_t
#else
#define FNV_PRIME 16777619
#define FNV_SIGNED int32_t
#define FNV_UNSIGNED uint32_t
#endif

uint64_t hs_hashable_init();

FNV_UNSIGNED hashable_fnv_hash(const unsigned char* str, FNV_SIGNED len, FNV_UNSIGNED salt);
FNV_UNSIGNED hashable_fnv_hash_offset(const unsigned char* str, FNV_SIGNED offset, FNV_SIGNED len, FNV_UNSIGNED salt);

#endif

0 comments on commit b88e9b3

Please sign in to comment.