| 2227 | } |
| 2228 | |
| 2229 | inline void read_file(const std::string &path, std::string &out) { |
| 2230 | std::ifstream fs(path, std::ios_base::binary); |
| 2231 | fs.seekg(0, std::ios_base::end); |
| 2232 | auto size = fs.tellg(); |
| 2233 | fs.seekg(0); |
| 2234 | out.resize(static_cast<size_t>(size)); |
| 2235 | fs.read(&out[0], static_cast<std::streamsize>(size)); |
| 2236 | } |
| 2237 | |
| 2238 | inline std::string file_extension(const std::string &path) { |
| 2239 | std::smatch m; |
no test coverage detected