I've got a function that takes two parameters, for example:
let f a b = a = b
Then I have a second function that returns a tuple:
let g = (a, b)
I want to pass in a and b in the tuple from g as parameters to f in one line. I could do it in two statements, but the reason I want to do this is that my calling function does an or and I'd rather not call f unless the first case is false, to save on unnecessary processing.
let calling =
someboolean ||
f g // want to split result of g to parameters for f without calling g twice
Any tips on how to do this? I know I could have f take a tuple instead, but I'd like to retain the option for currying.
I hope I explained this well enough. :)