Function remove_from_end

Summary

#include "breeze/text/remove_from_end.hpp"

(1) std::string remove_from_end(std::string const &s, std::string const &to_be_removed)

(2) std::string remove_from_end(std::string const &s, char c)

Function overload

Synopsis

#include "breeze/text/remove_from_end.hpp"

std::string remove_from_end(std::string const &s, std::string const &to_be_removed)

Description

Returns
If s ends with to_be_removed, s with the to_be_removed part erased from its end; otherwise a copy of s.

Source

Line 30 in breeze/text/remove_from_end.hpp.

Synopsis

#include "breeze/text/remove_from_end.hpp"

std::string remove_from_end(std::string const &s, char c)

Description

Returns
If s ends with c, s with the last character removed; otherwise a copy of s.

Source

Line 40 in breeze/text/remove_from_end.hpp.