Specifically, it is monkey patching the unary - and + operators on array, and has a clever global method missing.
The unary operators `def -@` gets called when you do something like: `-[1,2,3]`.
So in the example code at the bottom, it's doing `bar =+ [x | x <- [1..3]]` that's better parsed as `bar = +[x | x <- [1..3]]` (note the spacing difference).
Comments
Specifically, it is monkey patching the unary - and + operators on array, and has a clever global method missing.
The unary operators `def -@` gets called when you do something like: `-[1,2,3]`.
So in the example code at the bottom, it's doing `bar =+ [x | x <- [1..3]]` that's better parsed as `bar = +[x | x <- [1..3]]` (note the spacing difference).
Hacking unary operators has a long history in silliness in ruby. See also: https://github.com/jicksta/superators