A safety improvement on LocalStorage.
A safety improvement on LocalStorage.

In concurrent writes, some threads will use the thread-static dictionary
for buffering their write into an IShielded. Only one can use the fast local
fields of the IShielded's LocalStorage. Later, when those fast fields
become free, one of those using the dictionary could now start using
the fields, but LS would "forget" to remove it's entry from the dictionary
in that case!

However, this never happened because the LocalStorage is used just to
hold a wrapper, which is a constant during a transaction. I.e. threads
wouldn't change the value in a LocalStorage, they would always first remove
it. I could have asserted this write-then-remove usage, or supported both
by fixing the bug. I chose the latter.
wizardbeard/Shielded,jbakic/Shielded