| 83 | |
| 84 | template <class T, class TStripCriterion> |
| 85 | static inline bool StripString(const T& from, T& to, TStripCriterion&& criterion) { |
| 86 | auto b = from.begin(); |
| 87 | auto e = from.end(); |
| 88 | |
| 89 | if (StripRange(b, e, criterion)) { |
| 90 | if constexpr (::TIsTemplateBaseOf<std::basic_string_view, T>::value) { |
| 91 | to = T(b, e); |
| 92 | } else { |
| 93 | to.assign(b, e); |
| 94 | } |
| 95 | |
| 96 | return true; |
| 97 | } |
| 98 | |
| 99 | to = from; |
| 100 | |
| 101 | return false; |
| 102 | } |
| 103 | |
| 104 | template <class T, class TStripCriterion> |
| 105 | [[nodiscard]] static inline T StripString(const T& from, TStripCriterion&& criterion) { |
nothing calls this directly
no test coverage detected