~/talk

Tail Call Optimization: The Musical!!

Talkat !!Con 2019 · 2019-06-01..06-03· [javascript]
slides:none on file

Demonstrates that a JavaScript engine with Tail Call Optimization actually reclaims stack frames so a tail‑recursive function can run tens of thousands of calls without throwing Maximum call stack size exceeded the demo rewrites a naive recursive routine into an accumulator style with a nonrecursive wrapper to make it tail‑recursive, flips the TCO switch and runs ~10,000 calls successfully, noting the tradeoff of losing intermediate stack trace information.

AI-written summary · about

  1. 0:00Intro
  2. 0:58Stack Overflow
  3. 4:04Tail Recursive
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.