Added ldoc comments for all lua modules and generated docs in documentation index.html

This commit is contained in:
SkylarHew
2022-01-20 11:04:44 -07:00
parent 5085d87f68
commit da7b996a8b
41 changed files with 4307 additions and 35 deletions

View File

@ -1,7 +1,12 @@
--- Miscellaneous functions
-- @module modpol.util.misc
modpol.util = {}
--- @function modpol.copy_table
-- Returns a copy of the table inputted
--- Returns a copy of the table inputted
-- @function modpol.util.copy_table
-- @param t table to copy
-- @return copy of table
function modpol.util.copy_table(t)
local t2 = {}
for k,v in pairs(t) do
@ -10,8 +15,10 @@ function modpol.util.copy_table(t)
return t2
end
--- @function modpol.copy_table
-- Returns the number of elements in a pairs table
--- Returns the number of elements in a pairs table
-- @function modpol.util.num_pairs
-- @param t pairs table
-- @return number of elements in pairs table
function modpol.util.num_pairs(t)
local i = 0
for k,v in pairs(t) do