Don't replace placeholders incorrectly when expandtab=0

Fixes issue #143