by uryga · 6y ago · 0 comments
fun note: C-- has something like that! iirc it's like calling a function, but reusing the current stackframe:
jump f(expr1,. . .,exprn);
> "the `jump` statement performs a control jump but carrying parameters. It has as target [...] a procedure address and can optionally transfer arguments to that procedure."https://www.microsoft.com/en-us/research/wp-content/uploads/...
The concept is not so unique as you might think tho; the more commonly used term is "tail call".
re: C--, i think it's mostly used as a compiler IR. (notably in Haskell's GHC)