diff options
author | Hans Goudey <h.goudey@me.com> | 2021-04-15 15:54:30 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2021-04-15 15:54:30 +0300 |
commit | d9cb1fa7dcd2735d76a0c5b962600d5060481064 (patch) | |
tree | a9cda392a564691bed620e52b1c081b5bbce1925 /source/blender/blenlib | |
parent | e7516174c70e1de5a3d8e870ff8c62dfdfd18d90 (diff) | |
parent | ecc2db8a3a74ff11f2d7e46fbfa28f1ebe58b9ed (diff) |
Merge branch 'master' into geometry-nodes-curve-support
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r-- | source/blender/blenlib/BLI_multi_value_map.hh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/blenlib/BLI_multi_value_map.hh b/source/blender/blenlib/BLI_multi_value_map.hh index 98b55067a5c..fb52ac78243 100644 --- a/source/blender/blenlib/BLI_multi_value_map.hh +++ b/source/blender/blenlib/BLI_multi_value_map.hh @@ -73,6 +73,12 @@ template<typename Key, typename Value> class MultiValueMap { vector.append(std::forward<ForwardValue>(value)); } + void add_non_duplicates(const Key &key, const Value &value) + { + Vector<Value> &vector = map_.lookup_or_add_default_as(key); + vector.append_non_duplicates(value); + } + /** * Add all given values to the key. */ |