• bitcrafter
    link
    fedilink
    arrow-up
    8
    ·
    2 months ago

    In civilized languages tail recursion takes care of this for you. 😁

    • bss03@infosec.pub
      link
      fedilink
      English
      arrow-up
      5
      ·
      2 months ago

      gcc can do tail-call optimization in C, and sometimes in C++. It doesn’t even have to be a recursive call, tho I do think it might depends on the calling convention.