lua-users home
lua-l archive

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


function f(...)
  print(...)
end

function f(...)
  for k,v in {...} do
    op( v )
  end
end

function f(...)
  for i=1,select('#',...) do
    op( select(i, ...) )
  end
end

Though for anything but very short argument lists (3 or 4), it's
faster to use 'arg' if you need to iterate -- at least with 5.1w1.