Skip to content

Trim analyzer should warn on unnecessary DynamicallyAccessedMembers #109802

@sbomer

Description

@sbomer

Context: #109772 (comment)

It would be nice if the analyzer could warn on DynamicallyAccessedMembers annotations that preserve more than is necessary. This would be hard to do when a Type "escapes" to an annotated field, but sounds reasonable at least when the dataflow only involves annotated method parameters.

This would help move away from DynamicallyAccessedMembers.All annotations to the less broad annotations added for #88512.

Metadata

Metadata

Assignees

No one assigned

    Labels

    area-Tools-ILLink.NET linker development as well as trimming analyzers

    Type

    No type

    Projects

    Status

    No status

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions