MCPcopy Create free account
hub / github.com/apache/brpc / remove_last_char

Function remove_last_char

src/brpc/restful.cpp:30–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

28extern bool is_url_char(char c);
29
30inline butil::StringPiece remove_last_char(butil::StringPiece s) {
31 if (!s.empty()) {
32 s.remove_suffix(1);
33 }
34 return s;
35}
36
37std::ostream& operator<<(std::ostream& os, const RestfulMethodPath& p) {
38 if (!p.service_name.empty()) {

Callers 2

restful.cppFile · 0.85
to_stringMethod · 0.85

Calls 2

remove_suffixMethod · 0.80
emptyMethod · 0.45

Tested by

no test coverage detected