News for hackers. Stuff that matters.
Re:Java 21 makes me like Java again by waffletower on Sunday September 17, 2023 @12:24AM (#37541513)
Yes, short abbreviations are brutal in long sprawling code contexts. Write in a compact, functional, and readily unit testable coding style, and those tiny variables reduce your cognitive load and bring great clarity. Use comments and/or docstrings to provide context for compact parameters and local variables once, rather than implicitly documenting with every usage.
Re:Java 21 makes me like Java again by ctxc on Sunday September 17, 2023 @01:59AM (#37541960)
>Use comments and/or docstrings to provide context for compact parameters and local variables once, rather than implicitly documenting with every usage.

Context that isn't documented with every usage is context you need to remember. Trade off, but I'd much rather not have to remember multiple contexts for the same name every few hundred lines.