MCPcopy Create free account
hub / github.com/p-ranav/tabulate / trim_left

Method trim_left

include/tabulate/format.hpp:726–731  ·  view source on GitHub ↗

trim white spaces from the left end of an input string

Source from the content-addressed store, hash-verified

724
725 // trim white spaces from the left end of an input string
726 static std::string trim_left(const std::string &input_string) {
727 std::string result = input_string;
728 result.erase(result.begin(), std::find_if(result.begin(), result.end(),
729 [](int ch) { return !std::isspace(ch); }));
730 return result;
731 }
732
733 // trim white spaces from right end of an input string
734 static std::string trim_right(const std::string &input_string) {

Callers

nothing calls this directly

Calls 2

beginMethod · 0.45
endMethod · 0.45

Tested by

no test coverage detected