1
0
Fork 0
mirror of https://github.com/beefytech/Beef.git synced 2025-06-10 12:32:20 +02:00

Update Enumerator version when removing key

This commit is contained in:
disarray2077 2021-06-24 20:19:47 -03:00
parent 709997feb1
commit ce894beaa9

View file

@ -868,6 +868,9 @@ namespace System.Collections
{
int_cosize curIdx = mIndex - 1;
mDictionary.Remove(mDictionary.mEntries[curIdx].mKey);
#if VERSION_DICTIONARY
mVersion = mDictionary.mVersion;
#endif
mIndex = curIdx;
}
@ -1016,6 +1019,9 @@ namespace System.Collections
{
int_cosize curIdx = mIndex - 1;
mDictionary.Remove(mDictionary.mEntries[curIdx].mKey);
#if VERSION_DICTIONARY
mVersion = mDictionary.mVersion;
#endif
mIndex = curIdx;
}
@ -1119,6 +1125,9 @@ namespace System.Collections
{
int_cosize curIdx = mIndex - 1;
mDictionary.Remove(mDictionary.mEntries[curIdx].mKey);
#if VERSION_DICTIONARY
mVersion = mDictionary.mVersion;
#endif
mIndex = curIdx;
}