no more fooling with globals in LDoc; the class ModuleMap is no longer global, but inserted into doc module so it can use it

This commit is contained in:
steve donovan 2013-11-16 21:03:43 +02:00
parent fd323aa286
commit 4666e464cc
2 changed files with 4 additions and 4 deletions

View File

@ -82,8 +82,8 @@ local Item,File,Module = doc.Item,doc.File,doc.Module
local quit = utils.quit
class.ModuleMap(KindMap)
local ModuleMap = ModuleMap
local ModuleMap = class(KindMap)
doc.ModuleMap = ModuleMap
function ModuleMap:_init ()
self.klass = ModuleMap
@ -97,7 +97,7 @@ ModuleMap:add_kind('lfunction','Local Functions','Parameters')
ModuleMap:add_kind('annotation','Issues')
class.ProjectMap(KindMap)
local ProjectMap = class(KindMap)
ProjectMap.project_level = true
function ProjectMap:_init ()

View File

@ -264,7 +264,7 @@ function File:finish()
if not submodule then
this_mod.package = package
this_mod.mod_name = mname
this_mod.kinds = ModuleMap() -- the iterator over the module contents
this_mod.kinds = doc.ModuleMap() -- the iterator over the module contents
self.modules:append(this_mod)
end
elseif doc.section_tag(item.type) then