This would belong in StringUtil.cpp/h.