Replies: 1 comment 3 replies
-
We did not feel there was good reason for the names to differ, and more often than not it indicated an unintended deviation in teh minds of most developers.
Yes. But this is considered not a good thing now as it just means changes in one location don't properly happen elsewhere. It is generally discouraged. With tuples we didn't want to make the same mistake, so we took a more firm stance on it. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I have that code:
And I don't understand why this is an error.
We can rename parameter when overriding (
param
tomultiplier
).Or assign tuple to a differently named tuple, including in Generic (
List<(bool isCorrect, int size)> list = new List<(bool, int)>()
).For this specific usage, I can't know the name inside the Interface, but it's useful to have tuple name in the implementation (having to use
values.Item1
isn't very much readable)So why this specific case doesn't work ?
It could be a warning, or ignored (like the other case with tuple).
Beta Was this translation helpful? Give feedback.
All reactions