Skip to content

IsExternalInit not generated correctly in multitargeting projects #98

@Lordfirespeed

Description

@Lordfirespeed

Reproduction Steps

Make a project that targets netstandard2.1 and net8.0

<TargetFrameworks>netstandard2.1;net8.0</TargetFrameworks>

and add a record class to it with some members, or alternatively a class with required init properties.

Expected Behavior

IsExternalInits type should be included in the compiled assembly targeting netstandard2.1.

Actual Behavior

Compilation succeeds, but IsExternalInits type is not included in the compiled assembly targeting netstandard2.1.

System info

This section should contain useful info such as:

  • PolySharp NuGet version 1.14..1
  • Operating system version Pop!_OS (Ubuntu) 22.04
  • .NET SDK version 8.0.100
  • Runtime is Unity 2022.3.9f1 (implements net48 and netstandard2.1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs more infoCan't repro or unclear issue, needs further info

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions