diff options
| author | 2022-11-05 12:10:19 +0100 | |
|---|---|---|
| committer | 2022-11-05 11:10:19 +0000 | |
| commit | bcb80d3ff4a669d52d63950c8830427646c05884 (patch) | |
| tree | 4aa95a83545b3f87a80fe4b625cb6f2ad9c4427f /vendor/github.com/cornelk/hashmap/defines.go | |
| parent | [bugfix] Increase field size limits when registering apps (#958) (diff) | |
| download | gotosocial-bcb80d3ff4a669d52d63950c8830427646c05884.tar.xz | |
[chore] bump gruf/go-store to v2 (#953)
* [chore] bump gruf/go-store to v2
* no more boobs
Diffstat (limited to 'vendor/github.com/cornelk/hashmap/defines.go')
| -rw-r--r-- | vendor/github.com/cornelk/hashmap/defines.go | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/vendor/github.com/cornelk/hashmap/defines.go b/vendor/github.com/cornelk/hashmap/defines.go new file mode 100644 index 000000000..75f0e9eb3 --- /dev/null +++ b/vendor/github.com/cornelk/hashmap/defines.go @@ -0,0 +1,12 @@ +package hashmap + +// defaultSize is the default size for a map. +const defaultSize = 8 + +// maxFillRate is the maximum fill rate for the slice before a resize will happen. +const maxFillRate = 50 + +// support all numeric and string types and aliases of those. +type hashable interface { + ~int | ~int8 | ~int16 | ~int32 | ~int64 | ~uint | ~uint8 | ~uint16 | ~uint32 | ~uint64 | ~uintptr | ~float32 | ~float64 | ~string +} |
