MCPcopy Create free account
hub / github.com/boostorg/parser / file_slurp

Function file_slurp

example/json.cpp:324–334  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

322}
323
324std::string file_slurp(std::ifstream & ifs)
325{
326 std::string retval;
327 while (ifs) {
328 char const c = ifs.get();
329 retval += c;
330 }
331 if (!retval.empty() && retval.back() == -1)
332 retval.pop_back();
333 return retval;
334}
335
336int main(int argc, char * argv[])
337{

Callers 1

mainFunction · 0.70

Calls 3

backMethod · 0.80
getMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected