Skip to content

Fix nullable annotation of AsnEncodedData.RawData#37572

Closed
stephentoub wants to merge 1 commit intodotnet:masterfrom
stephentoub:rawdatannotation
Closed

Fix nullable annotation of AsnEncodedData.RawData#37572
stephentoub wants to merge 1 commit intodotnet:masterfrom
stephentoub:rawdatannotation

Conversation

@stephentoub
Copy link
Member

@bartonjs, this fixes the nullable annotation of AsnEncodedData.RawData to be nullable.

Are you sure you want to go this route, rather than making it so that RawData never returns null? This is correct based on the current implementation, but the fallout is non-trivial, and it definitely seems to be penalizing the common case.

@ghost
Copy link

ghost commented Jun 8, 2020

Tagging subscribers to this area: @bartonjs, @vcsjones, @krwq
Notify danmosemsft if you want to be subscribed.

@bartonjs
Copy link
Member

bartonjs commented Jun 8, 2020

Yeah, OK, back to my original position of "let's call it non-nullable". So I guess we'll introduce a behavioral change from NetFX regarding the few places that are checking for null, but if it's just things like Pkcs9DocumentName in their default ctor, that's not really something people use (the infrastructure uses it, then calls CopyFrom, or CopyTo, or whatever; and actual value creators would use the byte[] or string ctors).

@stephentoub
Copy link
Member Author

Replaced by #37598

@stephentoub stephentoub closed this Jun 8, 2020
@stephentoub stephentoub deleted the rawdatannotation branch October 12, 2020 00:29
@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.

3 participants