176
you are viewing a single comment's thread
view the rest of the comments
[-] marcos@lemmy.world -5 points 6 months ago

Da fuck?!

Where doe it declare it's a public property? Is it some kind of default now? Everything you write becomes one?

[-] Mozingo@lemmy.world 18 points 6 months ago

Right there where it says "public". What are you talking about?

[-] marcos@lemmy.world 4 points 6 months ago

Oh, right. I read it all wrong for a moment.

[-] victorz@lemmy.world 4 points 6 months ago

What do you mean? Why does what need to be a public property?

[-] hdsrob@lemmy.world 4 points 6 months ago

It's an Expression-Bodied Member (available since C#6). The expression (=>) is just syntactic sugar that the compiler recognizes as a single line property with only a getter (under the hood both versions compile the same).

this post was submitted on 07 Oct 2025
176 points (91.5% liked)

Programmer Humor

31210 readers
1243 users here now

Welcome to Programmer Humor!

This is a place where you can post jokes, memes, humor, etc. related to programming!

For sharing awful code theres also Programming Horror.

Rules

founded 2 years ago
MODERATORS