- 
                Notifications
    You must be signed in to change notification settings 
- Fork 5.2k
Closed as not planned
Labels
area-System.Text.RegularExpressionshelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributorsin-prThere is an active PR which will close this issue when it is mergedThere is an active PR which will close this issue when it is merged
Milestone
Description
If a developer specifies RegexOptions.IgnorePatternWhitespace or uses the (?x) inline option, they can embed # comments inside their regex pattern.  Today the parser simply throws these away.  When in the context of the source generator, we could instead store them and try to propagate them to the generated C# code as C# comments at an appropriate location in the source.
GSPP, D3-LucaPiombino and WeihanLiCopilot
Metadata
Metadata
Assignees
Labels
area-System.Text.RegularExpressionshelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributorsin-prThere is an active PR which will close this issue when it is mergedThere is an active PR which will close this issue when it is merged