Backport XML documentation for CustomReflectionContext#124365
Backport XML documentation for CustomReflectionContext#124365
Conversation
Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
|
Tagging subscribers to this area: @dotnet/area-system-reflection |
… src remarks Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
Addressed all feedback in commit 865415d:
|
Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
This PR backports XML documentation from dotnet-api-docs to the runtime repository for the CustomReflectionContext class, following the established pattern from PR #124227. The documentation provides IntelliSense support for developers using this reflection API.
Changes:
- Added comprehensive XML documentation to
CustomReflectionContextclass including type-level summary, simplified remarks with a link to supplemental documentation, and complete member-level documentation - All public and protected members now have summaries, parameter descriptions, return value documentation, and brief contextual remarks where appropriate
- Followed the established convention of not adding documentation to ref assemblies
Co-authored-by: gewarren <24882762+gewarren@users.noreply.github.com>
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This comment has been minimized.
This comment has been minimized.
|
@ericstj There's a build failure that I don't see in other PRs. Could it be due to the way docs are added for the platform not supported stubs? @azure-pipelines eng\targetingpacks.targets(107,5): error : (NETCORE_ENGINEERING_TELEMETRY=Build) The shared framework must be built before the local targeting pack can be consumed. |
🤖 Copilot Code Review — PR #124365Note This review was AI-generated by Copilot using multi-model analysis (Claude Opus 4.5, GPT 5.3 Codex, Goldeneye, Claude Opus 4.6). Holistic AssessmentMotivation: Justified — Approach: Correct — XML doc comments are added directly to the source file for all public/protected members, following the standard dotnet/runtime documentation approach. The Summary: ✅ LGTM. This is a well-crafted documentation-only PR. All 9 public/protected members on Detailed Findings✅ Documentation Coverage — CompleteAll public/protected members (class summary, 2 constructors, ✅ Convention Compliance — Correct
✅ No New Public API SurfaceThe ref assembly ( 💡 Missing
|
|
/ba-g Failures unrelated |
When `UseCompilerGeneratedDocXmlFile` is `true` (the default) and a library is a PNSE assembly, `eng/intellisense.targets` adds a self-referencing `ProjectReference` with `SetTargetFramework=net11.0` to pull enriched XML docs from the non-PNSE sibling build. In the NET481 build leg the local targeting pack (`FrameworkList.xml`) is never produced, so the inner `net11.0` build fails with: > The shared framework must be built before the local targeting pack can be consumed. This became visible after #124365 removed `<UseCompilerGeneratedDocXmlFile>false</UseCompilerGeneratedDocXmlFile>` from `System.Reflection.Context`, activating the PNSE doc-source path for the first time in that project. ### Fix Disable `AddProjectReferenceToPNSEDocSource` when doing a vertical build that is not for .NETCore. This also fixes a build break in VB tests that was introduced while the NETFx build was broken. ### Verification Tested locally by building vertical builds for NETFx, Net11, and packages. Fixes #127007 --------- Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Co-authored-by: Eric StJohn <ericstj@microsoft.com> Co-authored-by: Jan Kotas <jkotas@microsoft.com>
Backports XML documentation from dotnet-api-docs to the runtime repository per #124227.
Description
Adds comprehensive XML documentation to the
CustomReflectionContextclass and all its public/protected members to provide IntelliSense support for developers using this reflection customization API.Changes:
CustomReflectionContextclass in src assembly with summary and simplified type-level remarksMapAssembly,MapType,GetCustomAttributesoverloads,AddProperties,CreatePropertyoverloads)https://github.com/dotnet/docs/raw/main/docs/fundamentals/runtime-libraries/system-reflection-context-customreflectioncontext.mdAddPropertiesandCreatePropertymethods)Customer Impact
Developers using
System.Reflection.Contextwill have IntelliSense documentation with summaries, parameter descriptions, and brief contextual remarks for all members, plus a link to comprehensive documentation showing how to customize reflection behavior through attribute manipulation and virtual properties.Regression
No. Documentation-only change.
Testing
Risk
Minimal. Documentation-only change with no runtime impact.
Note: The netstandard2.0 target uses
GeneratePlatformNotSupportedAssemblyMessageand generates a stub from the ref assembly. Since the ref assembly has no XML docs (per guidelines), the generated stub lacks documentation. A solution for enabling compiler-generated docs for such assemblies is being determined by maintainers.💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.