MCPcopy Index your code
hub / github.com/CovenantSQL/CovenantSQL / IsEqual

Method IsEqual

crypto/hash/hash.go:106–114  ·  view source on GitHub ↗

IsEqual returns true if target is the same as hash.

(target *Hash)

Source from the content-addressed store, hash-verified

104
105// IsEqual returns true if target is the same as hash.
106func (h *Hash) IsEqual(target *Hash) bool {
107 if h == nil && target == nil {
108 return true
109 }
110 if h == nil || target == nil {
111 return false
112 }
113 return *h == *target
114}
115
116// Difficulty returns the leading Zero **bit** count of Hash in binary.
117// return -1 indicate the Hash pointer is nil.

Callers 15

verifyHashFunction · 0.95
TestHashFunction · 0.95
applyBlockMethod · 0.45
NewChainWithContextFunction · 0.45
applyBlockMethod · 0.45
getRemoteBPInfosMethod · 0.45
VerifyMethod · 0.45
VerifyAsGenesisMethod · 0.45
verifyMerkleRootMethod · 0.45
TestLocalKeyStoreFunction · 0.45
IsIDPubNonceValidFunction · 0.45

Calls

no outgoing calls

Tested by 8

TestHashFunction · 0.76
TestLocalKeyStoreFunction · 0.36
TestSaveLoadPrivateKeyFunction · 0.36
TestInitLocalKeyPairFunction · 0.36
TestDBFunction · 0.36
TestNewHashFromStrFunction · 0.36
TestCaller_CallNodeFunction · 0.36