Skip to content

Conversation

@nicholaspai
Copy link
Member

Leaving the counter i variable as uint256 removes gas cost to cast to uint32 and also prevents chance that leaf count will cause overflow, which is a risk with the increment logic ++i being inside an unchecked block.

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.

3 participants