use std::string as a container for char

That is what normally users would pass, so in some situations it
can avoid copying data.