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

[Feature Request]: .NET 6 Target with Trimming #2882

Closed
ds5678 opened this issue Jan 7, 2023 · 7 comments
Closed

[Feature Request]: .NET 6 Target with Trimming #2882

ds5678 opened this issue Jan 7, 2023 · 7 comments
Labels
Enhancement Areas for improvement

Comments

@ds5678
Copy link

ds5678 commented Jan 7, 2023

Context

This is a repost of #2673.

A .NET 6 target for the decompiler project with trimming would allow this to be used in trimmed or NativeAOT-compiled applications. This allows for applications to be smaller, faster, and more independent of user software installations.

Issues to be handled

Nullable Attributes

The issue mentioned in the last bullet point still hasn't been resolved. However, I have some alternatives:

Both of these are more actively maintained, and neither of them exhibit the issue that prevents multi-targeting.

On a more practical note, PolySharp has support for MemberNotNullAttribute and MemberNotNullWhenAttribute, which ReferenceAssemblyAnnotator does not.

@ds5678 ds5678 added the Enhancement Areas for improvement label Jan 7, 2023
@christophwille
Copy link
Member

MEF and NativeAot? Don't know if that will work.

@ds5678
Copy link
Author

ds5678 commented Jan 7, 2023

MEF

Is this referring to the Managed Extensibility Framework?

Edit: Yes it is.

@ds5678
Copy link
Author

ds5678 commented Jan 7, 2023

MEF and NativeAot? Don't know if that will work.

Even if trimming isn't feasible, do you mind if I do a pull request for PolySharp and .NET 6?

@dgrunwald
Copy link
Member

I don't see a need to introduce PolySharp here. We should be able to use ReferenceAssemblyAnnotator for .NET Core 2; and we shouldn't need anything extra at all for .NET 6?

@ds5678
Copy link
Author

ds5678 commented Jan 7, 2023

I don't see a need to introduce PolySharp here.

If nothing else, you'll be able to use MemberNotNullAttribute and MemberNotNullWhenAttribute which are not available from ReferenceAssemblyAnnotator.

However, PolySharp also inserts numerous other classes, such as [UnscopedRef], which could potentially benefit your customers if used in ILSpy.

@christophwille
Copy link
Member

Unless a customer specifically asks for that we won't do it. Just because is not a valid justification.

@ds5678
Copy link
Author

ds5678 commented Jan 7, 2023

It sounds like I am not welcome here.

@ds5678 ds5678 closed this as not planned Won't fix, can't repro, duplicate, stale Jan 7, 2023
@icsharpcode icsharpcode locked and limited conversation to collaborators Jan 8, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Enhancement Areas for improvement
Projects
None yet
Development

No branches or pull requests

3 participants