a few fixes to the compiler from code review.
restore dot writer.