News for hackers. Stuff that matters.
Re:Ask HN: If your code no longer makes sense to you, do you... by extasia on Sunday July 02, 2023 @06:29PM (#36566469)
Interesting. I'm quite the opposite in that I'll try pretty hard to avoid unnecessary allocations. In the case of your example I'd do something like:

  variable = foo(bar(baz(stuff)));
  // baz stuff
  // then bar the result
  // which we finally foo. 
I primarily write python which can't optimize out the allocations so that might influence this.

There are no comments on this comment yet.