From dbc6eda60967551d3dc83c9152f89bf6a0ac183e Mon Sep 17 00:00:00 2001 From: Tyge Løvset Date: Sun, 13 Sep 2020 15:08:29 +0200 Subject: added cmap_emplace_n() --- stc/cmap.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/stc/cmap.h b/stc/cmap.h index 6447d1a6..b8e53ffe 100644 --- a/stc/cmap.h +++ b/stc/cmap.h @@ -237,9 +237,9 @@ typedef struct {size_t idx; uint32_t hx;} cmap_bucket_t, cset_bucket_t; }) \ \ CMAP_ONLY_##ctype( \ - STC_INLINE ctype##_##X##_result_t \ - ctype##_##X##_insert(ctype##_##X* self, cmap_##X##_input_t pair) { \ - return ctype##_##X##_emplace(self, pair.key, pair.value); \ + STC_INLINE void \ + ctype##_##X##_emplace_n(ctype##_##X* self, const cmap_##X##_input_t pairs[], size_t n) { \ + for (size_t i=0; i