Skip to content

Use Type.SatisfiesConstraints internally #962

@dotnetjunkie

Description

@dotnetjunkie

See: dotnet/runtime#28033

Possibly added to .NET 7 a future .NET version, the SatisfiesConstraints check allows Simple Injector to do a reliable test instead of catching the exception thrown by MakeGenericType, which prevents unwanted first chance exceptions.

Downside of implementing this is that a new build output is added to the Simple Injector package.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions