Skip to content

Document framework assembly access rule - #68493

Merged
PureWeen merged 2 commits into
dotnet:mainfrom
PureWeen:pureween-framework-assembly-access-rule
Aug 13, 2026
Merged

Document framework assembly access rule#68493
PureWeen merged 2 commits into
dotnet:mainfrom
PureWeen:pureween-framework-assembly-access-rule

Conversation

@PureWeen

@PureWeen PureWeen commented Aug 13, 2026

Copy link
Copy Markdown
Member

Documents the framework-wide rule against adding InternalsVisibleTo or [UnsafeAccessor] in shipping framework code to reach non-public members in another framework assembly. The assembly boundary should be redesigned instead; if that requires a public API, the repository API-review and baseline process applies.

This makes the guidance from #68365 (comment) durable for future contributors and coding agents, while clarifying that existing uses are not precedent for new ones.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@PureWeen
PureWeen requested a review from wtgodbe as a code owner August 13, 2026 16:11
Copilot AI lite review requested due to automatic review settings August 13, 2026 16:11
@PureWeen
PureWeen requested a review from a team as a code owner August 13, 2026 16:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Documents a framework-wide guideline in the repo’s Copilot instructions to avoid new cross-assembly access to non-public members via InternalsVisibleTo or UnsafeAccessor, and to prefer explicit public APIs via the API review/baseline process. This helps keep the guidance from #68365 durable and discoverable for future contributors and coding agents.

Changes:

  • Adds a new “Framework assembly boundaries” section to .github/copilot-instructions.md.
  • Explicitly states the rule against InternalsVisibleTo/UnsafeAccessor for new cross-assembly access.
  • Directs contributors to design public APIs and follow the API review/baseline process instead.
Show a summary per file
File Description
.github/copilot-instructions.md Adds durable guidance on respecting ASP.NET Core framework assembly boundaries and avoiding new cross-assembly non-public access bridges.

Review details

💡 Add a code-review agent skill for context-aware, tailored reviews. Learn more in the docs.

  • Files reviewed: 1/1 changed files
  • Comments generated: 0
  • Review effort level: Lite

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
@PureWeen
PureWeen merged commit 80de79a into dotnet:main Aug 13, 2026
10 checks passed
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-rc1 milestone Aug 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants