Discussion Thread: DIP 1032--Function pointers and Delegate Parameters...--Community Review Round 1

Paolo Invernizzi paolo.invernizzi at gmail.com
Sat Apr 4 10:47:33 UTC 2020


On Friday, 3 April 2020 at 23:05:52 UTC, Jonathan Marler wrote:

> (https://forum.dlang.org/post/plvqxehkjzxkvhsacjwp@forum.dlang.org), however, even if it was opt-in, I'm still not a huge fan of this feature.  Reason being that I favor making code "easier to read" rather than "easier to write".  Adding a new "attribute inheritance" semantic, whether implicitly or explicitly adds cognitive burden to the reader.  You now have to have extra knowledge about when attributes are inherited, whereas with the status quo, you don't have to think about it because all attributes are explicit.  And even if we make it opt in, now you have to learn a new syntax and/or attribute and how it works.  For me the benefit doesn't really justify the added complexity.

I totally agree with Jonathan: it's adding more complexity to the 
language without any specific reason, and D is complex enough 
IMHO.

Python has learned that long time ago: "Explicit is better than 
implicit".

I also don't agree with the rationale:

"is both surprising and burdensome" => opinabile, not for me for 
example, I don't find it surprising at all.
"will be welcome" => idem






More information about the Digitalmars-d mailing list