lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


You would need a different "keyword" to mark the intent to "leak" the resource. Hypothetical current-Lua code:

function sandbox.open(filename)
  assert(checkpath(filename))
  local f = assert(io.open(filename))
  -- some other processing on f
  return f
end