exp
exp copied to clipboard
A question about Dump
@cznic I use a array to creat a sub-array, and calle it's Dump function. It dumps all informations from root array.
And also Enumerator of a sub-array, will generate a iterator from root. Just a question, Thanks~
Assuming the subject is func (a *Array) Dump(w io.Writer) (err error): It should dump the Array (which can be a sub tree of any other array). I'm not sure what is meant by the term 'root array'. Please provide a small compilable example for me to see what output is generated and what is expected instead. It might be a bug.
I think the Enumerator method of the same object should return the same data set as Dump does, but, shame on me, it's not cleat from the documentation. I should improve it.
array := db.Array("name") subArray := array.Array("sub")
// array.Dump() is as same as subArray.Dump()
Thanks, now I understand clearly. I will investigate if that's intended (improve documentation) or if it's a bug (fix it).