// dumpNode writes a representation of the node v into the io.Writer.
dumpNode writes a representation of the node v into the io.Writer.
// dumpNode writes a representation of the node v into the io . Writer .
func (t *binTree) dumpNode(w io.Writer, v uint32, indent int) {
	if v == null {
		return
	}
	vn := &t.node[v]
	t.dumpNode(w, vn.r, indent+2)
	for i := 0; i < indent; i++ {
		fmt.Fprint(w, " ")
	}
	if vn.p == null {
		fmt.Fprintf(w, "node %d %q parent null\n", v, dumpX(vn.x))
	} else {
		fmt.Fprintf(w, "node %d %q parent %d\n", v, dumpX(vn.x), vn.p)
	}
	t.dumpNode(w, vn.l, indent+2)
}
func ( t * binTree ) dumpNode ( w io . Writer , v uint32 , indent int ) { if v == null { return } vn := & t . node [ v ] t . dumpNode ( w , vn . r , indent + 2 ) for i := 0 ; i < indent ; i ++ { fmt . Fprint ( w , " " ) } if vn . p == null { fmt . Fprintf ( w , " \n " , v , dumpX ( vn . x ) ) } else { fmt . Fprintf ( w , " \n " , v , dumpX ( vn . x ) , vn . p ) } t . dumpNode ( w , vn . l , indent + 2 ) }
dumpNode writes a representation of the node v into the io.Writer.
dumpNode writes a representation of the node v into the io . Writer .