>Lua 5.4 has const locals in loops. Each loop iteration gets a new j, >which is const. That is an interesting possibility. That said, the anonymous funcions in the example don't capture any upvalues so in theory there should be no difference.