In Haskell, if I write
fac n = facRec n 1
where facRec 0 acc = acc
facRec n acc = facRec (n-1) (acc*n)
and compile it with GHC
Your question isn't complete. I assume you mean GHC, and at least without optimizations the answer is "yes" because the worker function (facRec
in the first or fac
in the second) has an arity 2 compared to one and the assembly will reflect this. With optimizations or with JHC the answer is probably "no".