News for hackers. Stuff that matters.
Re:Mojo: It’s Finally Here by kstrauser on Thursday September 07, 2023 @02:47PM (#37423713)
Throwing this out there:

- I’ve used nonlocal 0 times ever.

- I get that people miss them, but you can define nested functions if you want. Nameless functions are nifty, but I’ve never lost sleep over putting `def foo` in front of what would’ve been a lambda in other languages.

- I kinda like the Python ternaries.

Preferences are A-OK, and I’m not saying you’re wrong. Just chiming in that the things you mention aren’t universally disliked.

Re:Mojo: It’s Finally Here by chombier on Thursday September 07, 2023 @03:47PM (#37424585)
> I’ve used nonlocal 0 times ever.

Same here, but I got bitten by weird scoping rules quite a few times.

Separating variable definition from assignment (e.g. with 'let') would probably help a lot in this case.