even more tests

This commit is contained in:
Erik Frojdh
2019-08-12 12:09:44 +02:00
parent f78a98797f
commit c36dfc3992
4 changed files with 36 additions and 43 deletions

View File

@ -1,18 +0,0 @@
#include "ToString.h"
namespace sls {
std::string ToString(const std::vector<std::string> &vec,
const char delimiter) {
std::ostringstream os;
if (vec.empty())
return os.str();
auto it = vec.cbegin();
os << *it++;
if (vec.size() > 1) {
while (it != vec.cend())
os << delimiter << *it++;
}
return os.str();
}
} // namespace sls