MCPcopy Create free account
hub / github.com/chen3feng/toft / StringTrimLeft

Function StringTrimLeft

base/string/algorithm.cpp:456–462  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

454}
455
456void StringTrimLeft(std::string* str) {
457 size_t start_pos = 0;
458 size_t end_pos = str->length();
459 while (start_pos != end_pos && isspace(str->at(start_pos)))
460 start_pos++;
461 *str = str->substr(start_pos);
462}
463
464std::string StringTrimLeft(const StringPiece& str)
465{

Callers

nothing calls this directly

Calls 5

substrMethod · 0.80
as_stringMethod · 0.80
find_first_not_ofMethod · 0.80
lengthMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected