▲ | middayc 17 hours ago | |
I agree. This is not something you would usually use to program, at least not all three together, but as it's written it's consistent and signals exactly what it does, to someone that knows Rye conventions / rules. I can break it down for you, but yes ... it's quite specific, I was trying to apply an `if` which is not something I needed to do or would look to do so far. The point is that you can also apply all "control structure like" functions, like any other function - consistency, not that this is advised or often used. ?word is a get word. `x: inc 10` evaluates inc function, so x is 11, but `x: ?inc` returns the inc function, so x is the builtin function. apply is a function that applies a function to a block of arguments. It's usefull when you want to be creative, but it's not really used in run of the mill code. .apply (op-word of apply) takes first argument from the left. `?print .apply [ "Hello" ]` Here we needed to take second argument from the left and this is what a * modifier at the end of the op- or pipe-word does. `[ "hello" ] .apply* ?print` You asked for it :P |