[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Documenting modules with LuaDoc in Lua 5.2
- From: James Graves <ansible@...>
- Date: Mon, 6 Dec 2010 17:51:07 -0600
I've had to mess around a little to get luadoc working properly in
this situation.
Here's what I've got at the top of one of my files:
--- Infinite Lists.
-- <br />
-- Various ways to construct infinite lists.
-- @class module
-- @name infinite_list
--[[ The module line is needed for luadoc to consider this a module.
module "infinite_list"
]]--
local M = {} -- List of exported functions.
The 'module' declaration is necessary, but commented out. The @class
and @name tags are also necessary.
>From there I define my functions. Since the exported functions are
defined as M.foo (to put them in the exported table), I also have to
put in a @name tag.
BR,
James