Skip to content

out of range when more than one key per value#7

Open
okwme wants to merge 1 commit intorob-Hitchens:masterfrom
okwme:master
Open

out of range when more than one key per value#7
okwme wants to merge 1 commit intorob-Hitchens:masterfrom
okwme:master

Conversation

@okwme
Copy link

@okwme okwme commented Oct 17, 2024

After entering the following kv pairs I was getting out of range panics when using rank or atRank:

{
  "0x000000000000000000000000c795344b1b30e3cfee1afa1d5204b141940cf445": 200,
  "0x00000000000000000000000021c8d946027dcada77f4dc90802ea9b906d3cce4": 268,
  "0x00000000000000000000000047e65bc714cd44959360ac0814a5fca0f5b07145": 268,
  "0x00000000000000000000000030ce3ced12f1facf02fe0da8578f809f5e4937e4": 400
}

Value 268 exists twice but while looping through the smaller became negative.

Maybe this didn't panic in older versions of solidity?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant