Bug fixes for dumping objects.
Some style modifications