Skip to content

Commit 7671ccd

Browse files
adamsitnikgewarren
andauthored
Improve TextWriter.NewLine docs (dotnet#8724)
* Improve TextWriter.NewLine docs, fixes dotnet#1477 * Apply suggestions from code review Co-authored-by: Genevieve Warren <[email protected]>
1 parent a123b2e commit 7671ccd

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

xml/System.IO/TextWriter.xml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -847,7 +847,8 @@
847847
<format type="text/markdown"><![CDATA[
848848
849849
## Remarks
850-
The default line terminator string is a carriage return followed by a line feed ("\r\n").
850+
851+
For non-Unix platforms, the default line terminator string is a carriage return followed by a line feed ('\r\n'). For Unix platforms, it's a line feed ('\n').
851852
852853
The line terminator string is written to the text stream whenever one of the `WriteLine` methods is called. In order for text written by the `TextWriter` to be readable by a <xref:System.IO.TextReader>, only "\n" or "\r\n" should be used as terminator strings. If `NewLine` is set to `null`, the default newline character is used instead.
853854

0 commit comments

Comments
 (0)