Add RegexOptions.AnyNewLine documentation#12405
Closed
danmoseley wants to merge 2 commits intodotnet:mainfrom
Closed
Add RegexOptions.AnyNewLine documentation#12405danmoseley wants to merge 2 commits intodotnet:mainfrom
danmoseley wants to merge 2 commits intodotnet:mainfrom
Conversation
Add documentation for the new AnyNewLine enum member (value 2048) that makes ^, $, \Z, and . recognize all Unicode newline sequences. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
|
Tagging subscribers to this area: @dotnet/area-system-text-regularexpressions |
Contributor
There was a problem hiding this comment.
Pull request overview
Adds API reference documentation for the new RegexOptions.AnyNewLine enum member introduced in .NET 11, describing how it changes newline handling for anchors and ..
Changes:
- Documented the
RegexOptions.AnyNewLineenum member (value2048). - Included behavioral details (supported newline sequences) and noted incompatibilities with
NonBacktrackingandECMAScript.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Member
Author
|
@gewarren can we merge? then I guess dotnet/docs#52328 will be green. |
Contributor
|
@danmoseley Is this for Preview 3? Normally we don't manually add docs like this. The CI imports it automatically. |
Member
Author
|
Ah! I didn't know that. I guess dotnet/docs#52328 should sit for a month or so then? |
Contributor
Yes, that would be best. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add API documentation for the new
RegexOptions.AnyNewLineenum member (value2048), shipping in .NET 11 Preview 3.AnyNewLinemakes^,$,\Z, and.recognize all Unicode newline sequences (\r\n,\r,\n,\u0085,\u2028,\u2029) instead of only\n. This addresses one of the most common pitfalls withSystem.Text.RegularExpressions-- that$doesn't match before\r\nand.matches\r.Related: