Fix a bug with deleted buckets in OFDictionary + a few optimizations.