prefix writer: simplify, preserve trailing \n
Merge pull request #78 from vito/simpler-prefix-writer

prefix writer: simplify, preserve trailing \n