zlacker

[parent] [thread] 1 comments
1. __s+(OP)[view] [source] 2024-02-24 12:47:29
By returning nil, the function makes it clear that it doesn't move the input reference
replies(1): >>stouse+d51
2. stouse+d51[view] [source] 2024-02-24 21:28:07
>>__s+(OP)
Yes, but now I have to keep track of which functions invalidate-and-return and which return nil. If I forget that `slices.Delete` returns a new slice instead of mutating in-place, the language doesn’t help me.
[go to top]