| 184 | /// Simple function to join a string |
| 185 | template <typename T> |
| 186 | std::string join(const T &v, std::string delim = ",") { |
| 187 | std::ostringstream s; |
| 188 | auto beg = std::begin(v); |
| 189 | auto end = std::end(v); |
| 190 | if (beg != end) s << *beg++; |
| 191 | while (beg != end) { |
| 192 | s << delim << *beg++; |
| 193 | } |
| 194 | return s.str(); |
| 195 | } |
| 196 | |
| 197 | /// Simple function to join a string from processed elements |
| 198 | template <typename T, typename Callable, |
no test coverage detected