function foo() local a = "embedded var"; return function () return a; end end foo();