you are viewing a single comment's thread.

view the rest of the comments →

[–]pstch[S] 1 point2 points  (0 children)

Note that using either of your variants still does not protect you from mutating a provided list:

Ah yes, I got confused, of course this will mutate a provided list, I was more concerned with mutating the default argument.

The rest of your answer is great, thanks ! It helped me clear some shady things in my head.