Conversation
Extract XML and Markdown documentation comment reading helpers (~440 lines) into a new XmlDocReader.fs file. These functions form a coherent unit (XML → ApiDocComment conversion) that does not depend on ReadingContext; they only need CrossReferenceResolver and the ApiDoc* types. - New: src/FSharp.Formatting.ApiDocs/XmlDocReader.fs - removeSpaces - readMarkdownCommentAsHtml - findCommand - readXmlElementAsSingleSummary / readXmlElementAsHtml - readXmlCommentAsHtmlAux / readXmlCommentAsHtml / readNamespaceDocs - combineHtml / combineHtmlOptions / combineComments / combineNamespaceDocs - Modified: SymbolReader.fs shrinks from 1703 → 1263 lines Part of #1022. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This was referenced Mar 8, 2026
…ader-23573bfba5b6339f
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.
🤖 This PR was created by Repo Assist, an automated AI assistant, in response to a
/repo-assistcommand from @dsyme on #1022.Closes (partial progress on) #1022
Summary
SymbolReader.fswas 1703 lines. This PR extracts the XML and Markdown documentation comment reading helpers (~440 lines) into a new, focusedXmlDocReader.fs, reducingSymbolReader.fsto 1263 lines.What moved into
XmlDocReader.fsThese functions form a coherent unit — they convert raw XML doc comments and Markdown doc comments into
ApiDocComment/ApiDocHtmlvalues — and have no dependency onReadingContext. They only needCrossReferenceResolverand theApiDoc*public types:removeSpacesreadMarkdownCommentAsHtmlLiterateDocumentintoApiDocCommentfindCommand[key:value]commands in comment textreadXmlElementAsSingleSummary<summary>in<pre>readXmlElementAsHtmlSummaryWithoutChildren<summary>elementsreadXmlCommentAsHtmlAuxApiDocCommentconversionreadXmlCommentAsHtml/readNamespaceDocscombineHtml/combineHtmlOptions/combineComments/combineNamespaceDocsFile sizes before/after
SymbolReader.fsXmlDocReader.fsThe remaining content of
SymbolReader.fsis:ReadingContext, the member/field/union-case readers, the inline-code link-wrapping helpers, comment-and-command readers (readCommentAndCommands,readCommentsInto), and the entity/namespace/assembly readers.Test Status
✅ Build succeeded (0 errors, 0 warnings)
✅ All 87 ApiDocs tests pass (4 pre-existing skips)
✅ Fantomas formatting applied
Fixes Split large files across the repository #1022