From ac736aa4ecf5dce7b1dbd4c5ef3758f8f2008ebc Mon Sep 17 00:00:00 2001 From: Ginger Bill Date: Sun, 15 Jan 2017 19:55:04 +0000 Subject: Procedure overloading --- src/map.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/map.c') diff --git a/src/map.c b/src/map.c index f974a46db..60af7f668 100644 --- a/src/map.c +++ b/src/map.c @@ -320,6 +320,7 @@ void _J2(MAP_PROC,multi_insert)(MAP_NAME *h, HashKey key, MAP_TYPE value) { if (h->hashes.count == 0) { _J2(MAP_PROC,grow)(h); } + // Make fr = _J2(MAP_PROC,_find)(h, key); i = _J2(MAP_PROC,_add_entry)(h, key); if (fr.entry_prev < 0) { @@ -329,6 +330,7 @@ void _J2(MAP_PROC,multi_insert)(MAP_NAME *h, HashKey key, MAP_TYPE value) { } h->entries.e[i].next = fr.entry_index; h->entries.e[i].value = value; + // Grow if needed if (_J2(MAP_PROC,_full)(h)) { _J2(MAP_PROC,grow)(h); } -- cgit v1.2.3