Skip to content

Move InternalsVisibleTo attribute to project file#210

Merged
304NotModified merged 1 commit into
masterfrom
copilot/185-implement-charset-detection
Jun 30, 2026
Merged

Move InternalsVisibleTo attribute to project file#210
304NotModified merged 1 commit into
masterfrom
copilot/185-implement-charset-detection

Conversation

Copilot AI commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Assembly-level attributes that control visibility should be declared in the project configuration rather than embedded in source files for better maintainability and clarity.

Changes:

  • Moved InternalsVisibleTo attribute from src/DetectionDetail.cs to src/UTF-unknown.csproj
  • Removed now-unnecessary System.Runtime.CompilerServices using directive

Before:

// src/DetectionDetail.cs
[assembly: InternalsVisibleTo("UtfUnknown.Tests, PublicKey=" +
"002400000480000094000000060200000024000052534131000400000100010029f6b4defac763...")]
namespace UtfUnknown;

After:

<!-- src/UTF-unknown.csproj -->
<ItemGroup>
  <InternalsVisibleTo Include="UtfUnknown.Tests, PublicKey=002400000480000094000000060200000024000052534131000400000100010029f6b4defac763..." />
</ItemGroup>

Copilot AI changed the title Move InternalsVisibleTo to csproj Move InternalsVisibleTo attribute to project file Jun 29, 2026
Copilot AI requested a review from 304NotModified June 29, 2026 22:18
@304NotModified 304NotModified added this to the 2.7 milestone Jun 30, 2026
@304NotModified 304NotModified marked this pull request as ready for review June 30, 2026 04:19
Copilot AI review requested due to automatic review settings June 30, 2026 04:19
@304NotModified 304NotModified linked an issue Jun 30, 2026 that may be closed by this pull request
@304NotModified 304NotModified merged commit c85bedb into master Jun 30, 2026
8 checks passed
@304NotModified 304NotModified deleted the copilot/185-implement-charset-detection branch June 30, 2026 04:20

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

This PR moves the InternalsVisibleTo assembly-level attribute out of a source file and into the SDK-style project file, aligning visibility configuration with project configuration for easier maintenance and clearer ownership.

Changes:

  • Added an <InternalsVisibleTo ... /> item in src/UTF-unknown.csproj for UtfUnknown.Tests (with the strong-name public key).
  • Removed the [assembly: InternalsVisibleTo(...)] attribute from src/DetectionDetail.cs.
  • Removed the now-unused System.Runtime.CompilerServices using directive from src/DetectionDetail.cs.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
src/UTF-unknown.csproj Adds InternalsVisibleTo as a project item so the SDK generates the assembly attribute during build.
src/DetectionDetail.cs Removes the embedded assembly attribute and the unused System.Runtime.CompilerServices using.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Move InternalsVisibleTo to csproj

3 participants