MCPcopy Create free account
hub / github.com/chain/txvm / treeFromBytes

Function treeFromBytes

protocol/state/serialize.go:60–69  ·  view source on GitHub ↗
(keys [][]byte)

Source from the content-addressed store, hash-verified

58}
59
60func treeFromBytes(keys [][]byte) (*patricia.Tree, error) {
61 tree := new(patricia.Tree)
62 for _, k := range keys {
63 err := tree.Insert(k)
64 if err != nil {
65 return nil, err
66 }
67 }
68 return tree, nil
69}

Callers 1

FromBytesMethod · 0.85

Calls 1

InsertMethod · 0.80

Tested by

no test coverage detected