#pragma once
typedef struct Map_Entry Map_Entry;
typedef struct Map Map;

struct Map_Entry {
    uint64_t key;
    uint64_t value;
};

struct Map {
    M_Allocator allocator;
    Map_Entry *entries;
    int cap;
    int len;
};

API void Map_Reserve(Map *map, int size);
API Map_Entry *Map_GetEntryBase(Map *map, uint64_t key);
API Map_Entry *Map_InsertEntry(Map *map, uint64_t key, uint64_t value);
API Map_Entry *Map_GetEntry(Map *map, uint64_t key);
API void Map_Insert(Map *map, S8_String keystr, void *value);
API void *Map_Get(Map *map, S8_String keystr);
API void Map_InsertU64(Map *map, uint64_t keystr, void *value);
API void *Map_GetU64(Map *map, uint64_t keystr);
API void *Map_GetP(Map *map, void *key);
API void Map_InsertP(Map *map, void *key, void *value);
API void Map_Insert2P(Map *map, void *key, void *value);