celestiaorg / celestiaorg/nmt

extract `computeRoot` to a separate method

Open
#261 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
122
Forks
53
Avg merge
1d 15h
Merged PRs (30d)
5

Description

I think this was simpler because `computeRoot` also operates on a few vars inside of the scope of the wrapping method (e.g. `subtreeRoots`). I think this was an optimization wrt to the recursive calls. I would merge as is but if benchmarks and readability improve or stay the same, I would not mind Evan's suggestion in a followup PR.

_Originally posted by @liamsi in https://github.com/celestiaorg/nmt/pull/260#discussion_r1648010073_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.