Skip to content

API similar to merge API of std::unordered_map #51

Description

@ParikaGoel

merge API in std::unordered_map ->
https://en.cppreference.com/w/cpp/container/unordered_map/merge.html

It provides the facility to avoid copying of {key,value} pairs. Entry from source container is extracted and inserted to destination container.
No elements are copied or moved, only the internal pointers of the container nodes are repointed.

In current implementation, insert API of tsl::ordered_map has a variant that copies the entries from source container to destination container. Since copying can be expensive, it will be useful to have the above mentioned functionality

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions