~kalon33/corsix-th/master

« back to all changes in this revision

Viewing changes to CorsixTH/Lua/utility.lua

  • Committer: corsixth.bot at gmail
  • Date: 2014-03-31 23:30:23 UTC
  • Revision ID: svn-v4:c39591fa-788f-11de-a72b-d90af8dea425:trunk:2687
Remove trailing whitespaces in .h, .cpp, .c and .lua files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
106
106
-- Can return the length of any table, where as #table_name is only suitable for use with arrays of one contiguous part without nil values.
107
107
function table_length(table)
108
108
  local count = 0
109
 
  for _,_ in pairs(table) do 
110
 
    count = count + 1 
 
109
  for _,_ in pairs(table) do
 
110
    count = count + 1
111
111
  end
112
112
  return count
113
113
end
142
142
  f:close()
143
143
  return loadstring_envcall(result, "@".. filename)
144
144
end
145
 
    
 
145
 
146
146
if rawget(_G, "loadin") then
147
147
  function loadstring_envcall(contents, chunkname)
148
148
    -- Lua 5.2 lacks setfenv(), but does provide loadin()