[Feature Request] [Longterm] Replace const-ref std::string arg with std::string_view #10110
Open
Description
The difference between the two is that reference references an object of type std::string which is defined to contain a unique buffer for its characters, while std::string_view describes a section of existing memory containing the characters. The previous arguments decleration style makes passing substring and static C-string to a function include an additional and (99% of the time) unneccessary step of allocating new buffer for and copying the characters to it, std::string_view argument does not have this flaw as it is capable of describing these sections of memory without copying them.