The doc for ReplaceLineEndings, however, talks about the replacement string being a LineEnding. Is there any chance I’m going to wake up one day with a new version of the IDE and suddenly find that this is now enforced?
I think I read it quite carefully. My example showed that a string which is not a line ending, will work. But the doc page talks throughout as if the replacement string is expected to be a line ending. In the context in which I want to use ReplaceLineEndings, I want to use a string which is not a line ending. I just don’t want to get any surprises down the road.
Not allowing that would break a LOT of existing code so I wouldn’t expect them to ever change that… but then again from recent experience, one never knows.
Then the documentation is misleading in calling the second parameter “LineEnding”. ReplaceLineEndings is a specialized version of ReplaceAll in that it doesn’t require a search string, but rather is aware of the 3 different kinds of line endings. The replacement can be anything. A very common usage is exactly what you are doing - forming a comma delimited string out of a list of terms that were one per line.