Skip to content

why fastcache not do hashcode collision? #63

@ahfuzhang

Description

@ahfuzhang

in file fastcache.go, func (b *bucket) Set, line 359:
b.m[h] = idx | (b.gen << bucketSizeBits)

I think the code should be:

if oldValue, ok := b.m[h]; ok{
    //do something, or the last key of same hashcode will lost
}

thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions