Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose internals of game/library project to editor and unit test projects by default #7205

Open
peter-r-g opened this issue Dec 19, 2024 · 2 comments
Labels
api design Opinions of nerds

Comments

@peter-r-g
Copy link

What it is?

Currently the internals of a game/library project cannot be consumed by the editor or unit test projects without the following attributes:

using System.Runtime.CompilerServices;

// Allows IDEs to compile.
[assembly: InternalsVisibleTo( "example.editor" )]
[assembly: InternalsVisibleTo( "example.unittest" )]

// Allows S&box to compile.
[assembly: InternalsVisibleTo( "package.local.example.editor" )]
[assembly: InternalsVisibleTo( "package.local.example.unittest" )]

What should it be?

The source generation should just generate these for you if they do not exist already. The editor and unit test projects are supplementary to the main project so it makes sense that they should have access to internal functionality.

@peter-r-g peter-r-g added the api design Opinions of nerds label Dec 19, 2024
@github-project-automation github-project-automation bot moved this to To triage in s&box tracker Dec 19, 2024
@garrynewman
Copy link
Member

I don't see any reason for this

@QuackCola
Copy link

I dunno what this would be for . Sounds similar to my issue here? #6284 unless I'm mistaking something.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api design Opinions of nerds
Projects
Status: To triage
Development

No branches or pull requests

3 participants