func (t *Txn) Clone() *Txn {
	t.writable = nil
	txn := &Txn{
		root: t.root,
		snap: t.snap,
		size: t.size,
	}
	return txn
}
Clone makes an independent copy of the transaction. The new transaction
does not track any nodes and has TrackMutate turned off. The cloned transaction will contain any uncommitted writes in the original transaction but further mutations to either will be independent and result in different radix trees on Commit. A cloned transaction may be passed to another goroutine and mutated there independently however each transaction may only be mutated in a single thread.
package iradix
import (
	"bytes"
	"strings"
	"github.com/hashicorp/golang-lru/simplelru"
)
const (
	defaultModifiedCache = 8192
)
type Tree struct {
	root *Node
	size int
}
func New() *Tree {
	t := &Tree{
		root: &Node{
			mutateCh: make(chan struct{}),
		},
	}
	return t
}
func (t *Tree) Len() int {
	return t.size
}
type Txn struct {
	root *Node
	snap *Node
	size int
	writable *simplelru.LRU
	trackChannels map[chan struct{}]struct{}
	trackOverflow bool
	trackMutate   bool
}
func (t *Tree) Txn() *Txn {
	txn := &Txn{
		root: t.root,
		snap: t.root,
		size: t.size,
	}
	return txn
}