Skip to content

What about Nullable struct? #11834

@gpetrou

Description

@gpetrou

Should there be some information here on whether to use or not the in-modifier with Nullable struct?
For example should we have
public void Method(int? arg) {}
or
public void Method(in int? arg) {}
?
ErrorProne.NET for example flags this as a special case: https://github.com/SergeyTeplyakov/ErrorProne.NET/blob/5cc962abfaf0005890dd0a9fba46a9e304a8a450/src/ErrorProne.NET.StructAnalyzers/TypeExtensions.cs#L28


Document Details

Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions