MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / getlines

Function getlines

src/plugin/test/opr_io_dump.cpp:122–132  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

120}
121
122std::vector<std::string> getlines(std::istream& inp, size_t skip_head = 0) {
123 std::vector<std::string> ret;
124 for (std::string line; std::getline(inp, line);) {
125 if (skip_head) {
126 --skip_head;
127 } else {
128 ret.emplace_back(std::move(line));
129 }
130 }
131 return ret;
132}
133
134} // anonymous namespace
135#if MGB_VERBOSE_TYPEINFO_NAME

Callers 1

TESTFunction · 0.85

Calls 1

emplace_backMethod · 0.80

Tested by

no test coverage detected