Wink.com is releasing a module called Dum for dumping data.
It derives from Dumper by Richard W Jones (now Std.dump in Extlib) and
from Size by Jean-Christophe Filliatre.
The main improvement over the original Dumper is that shared values
and therefore cycles are detected and labelled:
# let rec loopy = 1 :: 2 :: loopy in Dum.p loopy;;
- : string = "#0: (1 (2 #0))"
Dum was originally developed to print the maximum out of uncaught
exceptions, since the standard Printexc.to_string does not go arbitrarily
deep and this was occasionally a source of frustration.
Now data such as closure fields and object fields are dumped like regular
data without causing particular problems or worries.
The output is pretty-printed and its size limit is configurable.
Enjoy!
Martin, for Wink.
_______________________________________________
Caml-list mailing list. Subscription management:
http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
Archives: http://caml.inria.fr
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs