-- Sibling of calls/global.lua: same loop, but the function is bound to a
-- local up front so each call skips the globals lookup. The delta vs
-- calls/global.lua is the cost of per-call global resolution.
localfunctionadd_one(x)returnx+1endfunction_bench()localsum=0localf=add_onefori=1,1000dosum=f(sum)endreturnsumendfori=1,1500do_bench()endprint("calls/local: true")