Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Declare attributes on positional record property #44691

Closed
RikkiGibson opened this issue May 29, 2020 · 0 comments · Fixed by #45908
Closed

Declare attributes on positional record property #44691

RikkiGibson opened this issue May 29, 2020 · 0 comments · Fixed by #45908

Comments

@RikkiGibson
Copy link
Contributor

RikkiGibson commented May 29, 2020

It feels like it should be allowed to apply an attribute to the property associated with a positional record parameter. e.g.

// implicitly applies attribute to both parameter and property?
data class Record([MyAttr] string Prop);

or

data class Record([property: MyAttr] string Prop);

We should also consider nullable attributes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants