Efficiency of a code using partial function evaluation

The second one will work better. One important thing is that your trans function actually looks like (fun a num -> match ...). So, until the second argument has been applied, nothing will happen. As a consequence, let temp = trans true is actually slower because no computation is performed yet, but an allocation has to be performed so that the actual call can later remember that the first argument was true; moreover, that call is no longer a direct call to trans, but an indirect call to the closure containing both trans and true. So, your first variant introduces two sources of slowdown and no source of speedup.

Here is a third variant of your code:

let rec trans a = match a with
| true -> fun num -> num
| Candel s -> fun num -> let temp = trans true in (temp 1) + (temp 2)

This time, the execution can actually progress as soon as trans receives its first argument. So, it is no longer obvious which of the second or third variant is the fastest one, as there is now a trade-off between slowdown (closure allocation and call) and speedup (precomputing with just one argument).