Hi,

In message "Question about Marshal.dump behavior"
    on 02/08/06, " JamesBritt" <james / jamesbritt.com> writes:

|I had gotten the impression that the third parameter to Marshal.dump acted
|as a limit on the depth of the serialization.  One could use it to
|deliberately exclude data from serialization if it was stored in nested
|objects below a certain level.
|
|But I've run into some behavior that suggests that to use this parameter you
|have to know the complete depth of the target object; passing a number lower
|than that depth raises an exception.

|Is this behavior correct?  It seems the calling code has to know the depth
|of the object and any references it has, and is compelled to serialize the
|entire object.  Can one tell Marshal.dump to ignore objects below a certain
|depth (without writing your own _dump)?

Yes.  It's to avoid (almost) inifinite dump loop.  I didn't want
"dump" to dump incomplete object.  If someone come up with a better
idea, I'd like to hear.

							matz.