The default block parameter name seems small, but I feel like I'm gonna use it all the time, especially when I'm in the Rails console just trying to debug data
Also damn Nim needs to do a much better job with their docs and site. `nim result` returns this very outdated third-party link first and nothing else official.
I'm all for adding language features to avoid boilerplate, and it's clearly useful. I just want to call out that anonymous typing can be polarizing in large codebases and maybe only use it sparingly.
[it, (1..it).map { it * it }]
endHas an ambiguity, so you just add |x| to one of them..
nested_example = [1, 2, 3, 4, 5].map do |x|
[x, (1..x).map { x * it }]
endSeems like a mental over complication of a non-issue to me.
(This is terrible please don’t)
items.map { foo(_1) }
items.map { foo(it) }