Move ftostr into its last user (cppbackend) and simplify it a bit.