It would be useful to have an static_map::erase function to form a more complete API for static_map. Perhaps the simplest way to achieve this would be to use a "tombstone" sentinel value to indicate whether or not a slot contains an element that has been deleted. Another option would be to use an array of 1B atomic<state> for each slot. The lower 2 bits of this byte could be used to hold states such as empty, filling, filled, or deleted.
It would be useful to have an
static_map::erasefunction to form a more complete API forstatic_map. Perhaps the simplest way to achieve this would be to use a "tombstone" sentinel value to indicate whether or not a slot contains an element that has been deleted. Another option would be to use an array of 1Batomic<state>for each slot. The lower 2 bits of this byte could be used to hold states such asempty,filling,filled, ordeleted.