code: func initBlockNode(node *blockNode, blockHeader *wire.BlockHeader, parent *blockNode) {
  	*node = blockNode{
  		hash:       blockHeader.BlockHash(),
  		workSum:    CalcWork(blockHeader.Bits),
  		version:    blockHeader.Version,
  		bits:       blockHeader.Bits,
  		nonce:      blockHeader.Nonce,
  		timestamp:  blockHeader.Timestamp.Unix(),
  		merkleRoot: blockHeader.MerkleRoot,
  	}
  	if parent != nil {
  		node.parent = parent
  		node.height = parent.height + 1
  		node.workSum = node.workSum.Add(parent.workSum, node.workSum)
  	}
  }
docs: // initBlockNode initializes a block node from the given header and parent node,
  // calculating the height and workSum from the respective fields on the parent.
  // This function is NOT safe for concurrent access.  It must only be called when
  // initially creating a node.