ethereum-consensus icon indicating copy to clipboard operation
ethereum-consensus copied to clipboard

enhance safety of indexing operations

Open ralexstokes opened this issue 2 years ago • 0 comments

many places throughout the repo have direct indexing through std::ops::Index which will panic if the index is out of bounds

there are safer APIs like get on most index-able types and we should make a pass through the spec code to use this safer construction so that an error is returned in lieu of a bare panic

ralexstokes avatar Aug 23 '22 17:08 ralexstokes