Skip to content

Commit aa9b96b

Browse files
authored
fix comment about bitWidth (#72)
1 parent 726fc33 commit aa9b96b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

internal/internal.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ import (
1616
// nodes.
1717
//
1818
// The Bmap (bitmap) has the same number of bits as the "width" of the AMT
19-
// (bitWidth^2), where each bit in the bitmap indicates the presence (1) or
19+
// (2^bitWidth), where each bit in the bitmap indicates the presence (1) or
2020
// absence (0) of a value or link to a child node. In this way, the serialized
2121
// form, and in-memory form of a Node contains only the value or links present.
2222
// There must be at least one value for height=0 nodes and at least one link for
@@ -31,8 +31,8 @@ import (
3131
// values [Any]
3232
// } representation tuple
3333
//
34-
// Where bmap is strictly a byte array of length (bitWidth^2)/8 and the links
35-
// and values arrays are between zero and the width of this AMT (bitWidth^2).
34+
// Where bmap is strictly a byte array of length (2^bitWidth)/8 and the links
35+
// and values arrays are between zero and the width of this AMT (2^bitWidth).
3636
// One of links or values arrays must contain zero elements and one must contain
3737
// at least one element since a node is strictly either a leaf or a non-leaf.
3838
type Node struct {

0 commit comments

Comments
 (0)