Skip to content

Commit 5eac12e

Browse files
CopilotBillWagner
andauthored
Clarify raw string literal multi-line rules for opening quotes and whitespace handling (#47728)
* Initial plan * Clarify raw string literal multi-line rules for opening quotes and whitespace handling Co-authored-by: BillWagner <[email protected]> --------- Co-authored-by: copilot-swe-agent[bot] <[email protected]> Co-authored-by: BillWagner <[email protected]>
1 parent 24a2530 commit 5eac12e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

docs/csharp/language-reference/tokens/raw-string.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ Raw string literals can span multiple lines:
1717

1818
The following rules govern the interpretation of a multi-line raw string literal:
1919

20-
- The opening quotes must be the last non-comment token on its respective line, and the closing quote must be the first non-comment token on its respective line.
20+
- The opening quotes must be the last non-whitespace characters on their line, and the closing quotes must be the first non-whitespace characters on their line.
2121
- Any whitespace to the left of the closing quotes is removed from all lines of the raw string literal.
22-
- Whitespace following the opening quote on the same line is ignored.
22+
- Any whitespace following the opening quotes on the same line is ignored.
2323
- Whitespace only lines following the opening quote are included in the string literal.
2424
- If a whitespace precedes the end delimiter on the same line, the exact number and kind of whitespace characters (for example, spaces vs. tabs) must exist at the beginning of each content line. Specifically, a space does not match a horizontal tab, and vice versa.
2525
- The newline before the closing quotes isn't included in the literal string.

0 commit comments

Comments
 (0)