News for hackers. Stuff that matters.
Re:Still in love with Rust by tragomaskhalos on Thursday November 22, 2018 @07:49AM (#18509669)
There is another Python feature that saves you from this trap however - the nested function. I have lots of code that looks like this:

    def txform_item(x):
      <maybe many lines, as complex as needed, + can see vars in outer scope>
    # right below, for optimal locality of ref for human reader
    new_list = [ txform_item(item) for item in old_list ]

There are no comments on this comment yet.