News for hackers. Stuff that matters.
Re:Push ifs up and fors down by gsuuon on Wednesday November 15, 2023 @06:00PM (#38283771)
The GOOD refactor would only work if the condition didn't depend on `walrus` and helps to make that fact explicit. If you apply "push fors down" again you end up with:

  if condition {
    frobnicate_batch(walruses)
  } else {
    transmogrify_batch(walruses)
  }

There are no comments on this comment yet.