More work on Text writer with null support, PMAP tweaks