Skip to content

Annotate TypeConverterAttribute so that the ILLinker preserves the ctor on the converter#39144

Merged
layomia merged 4 commits intodotnet:masterfrom
layomia:type_converter
Jul 24, 2020
Merged

Annotate TypeConverterAttribute so that the ILLinker preserves the ctor on the converter#39144
layomia merged 4 commits intodotnet:masterfrom
layomia:type_converter

Conversation

@layomia
Copy link
Contributor

@layomia layomia commented Jul 11, 2020

Fixes #39125

@layomia layomia added this to the 5.0.0 milestone Jul 11, 2020
@layomia layomia requested review from eerhardt and joperezr July 11, 2020 21:20
@layomia layomia self-assigned this Jul 11, 2020
@ghost
Copy link

ghost commented Jul 11, 2020

Tagging subscribers to this area: @safern
Notify danmosemsft if you want to be subscribed.

@layomia layomia requested a review from eerhardt July 23, 2020 01:08
Copy link
Member

@joperezr joperezr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a small question but otherwise this looks good!

@layomia
Copy link
Contributor Author

layomia commented Jul 24, 2020

@layomia layomia merged commit cbf79b6 into dotnet:master Jul 24, 2020
Copy link
Member

@eerhardt eerhardt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should have also removed this workaround which was linked to this bug:

// workaround TypeConverterAttribute not being annotated correctly
// https://github.com/dotnet/runtime/issues/39125
var _ = new MyStringConverter();

Jacksondr5 pushed a commit to Jacksondr5/runtime that referenced this pull request Aug 10, 2020
…or on the converter (dotnet#39144)

* Annotate TypeConverterAttribute so that the ILLinker preserves the ctor on the converter

* Address review feedback & add attributes to ref

* Use custom enum converter type

* Split tests
@layomia layomia deleted the type_converter branch August 10, 2020 23:18
@ghost ghost locked as resolved and limited conversation to collaborators Dec 8, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TypeConverterAttribute needs to be annotated so the ILLinker preserves the ctor on the converter

3 participants