Skip to content

Rose::StringUtility::fixLineTermination

Normalizes line termination.

Synopsis

Declared in <src/Rose/StringUtility/Convert.h>

[[visibility("default")]]
std::string
fixLineTermination(std::string const& input);

Description

Changes ASCII-based line termination conventions into LF (line-feed) termination. Any occurrence of CR+LF, LF+CR, or CR by itself (in that order of left-to-right matching) is replaced by a single LF character.

Return Value

String with normalized line endings.

Parameters

Name Description
input Input string to normalize.

Created with MrDocs