MCPcopy Create free account
hub / github.com/buger/jsonparser / sameTree

Function sameTree

parser.go:623–636  ·  view source on GitHub ↗

SYS-REQ-008

(p1, p2 []string)

Source from the content-addressed store, hash-verified

621
622// SYS-REQ-008
623func sameTree(p1, p2 []string) bool {
624 minLen := len(p1)
625 if len(p2) < minLen {
626 minLen = len(p2)
627 }
628
629 for pi_1, p_1 := range p1[:minLen] {
630 if p2[pi_1] != p_1 {
631 return false
632 }
633 }
634
635 return true
636}
637
638const stackArraySize = 128
639

Callers 3

EachKeyFunction · 0.85
EachKeyErrFunction · 0.85

Calls

no outgoing calls

Tested by 1