MCPcopy Create free account
hub / github.com/avast/retdec / unifyLineEnds

Function unifyLineEnds

src/utils/string.cpp:623–625  ·  view source on GitHub ↗

* @brief Unifies line ends in the given string to LF. * * @return String @a str with unified line ends. * In a greater detail, this function converts CRLF and CR inside @a str to LF. */

Source from the content-addressed store, hash-verified

621* In a greater detail, this function converts CRLF and CR inside @a str to LF.
622*/
623std::string unifyLineEnds(const std::string &str) {
624 return replaceAll(replaceAll(str, "\r\n", "\n"), "\r", "\n");
625}
626
627/**
628* @brief Returns @a str with backslashes before characters that need to be

Callers 2

getCommentForFuncMethod · 0.85
TEST_FFunction · 0.85

Calls 1

replaceAllFunction · 0.85

Tested by 1

TEST_FFunction · 0.68