Skip to content
Discussion options

You must be logged in to vote

@hhvdblom

The code I wrote for the Property is clean/short.

It is not clean, because it does not express well what is happening. When you write ShortRefControls = null;, then it looks like you're setting the property to null, but that's not what the setter does.

It has all the information whats needed.

I'd say that at the same time, it has too much information (the null value that is not actually relevant) and too little (it does not indicate in any way that it causes the property to be reset).

Regarding your question in the original post:

Is the C# language missing something?

Kind of. The case where a property can be read or written is supported well by C#. The case where a propert…

Replies: 25 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by YairHalberstadt
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
8 participants
Converted from issue

This discussion was converted from issue #2299 on October 22, 2020 12:38.