Skip to content

Support ref readonly parameters #16222

@vzarytovskii

Description

@vzarytovskii

Ref readonly are encoded as inrefs ([in] &T) with special attribute: https://github.com/jjonescz/csharplang/blob/5134bd7042bcd71dbddbdff618b9b63dc54775a0/proposals/ref-readonly-parameters.md#metadata-encoding

More info: https://discord.com/channels/143867839282020352/312132327348240384/1169766448063856650

Update 1: Intermediate ad-hoc fix (#16232) treats ref readonly as if it was inert in parameters. Proper fix should be introducing new byref type - readonlyref<_>, which should be a long-term fix.

cc @Tarmil @Sergio0694 @TIHan

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions