HAMT implements the following operations as atomic:

  • all insert operations
  • operator [] (key_type & key)
Atomicity means that if an exception is thrown by an operation from the list above, that operation has no effect. Any temporary resources allocated by the throwing operation will be freed upon its completion, and the container's state will remain unchanged if it already existed. HAMT operations not mentioned above as atomic, never throw.