From 1befcc505c29c7c23ad5f8b7fa24f91d2aabd891 Mon Sep 17 00:00:00 2001 From: steve donovan Date: Sun, 21 Aug 2011 17:29:56 +0200 Subject: [PATCH] problem with parsing explicit module() fixed --- ldoc/parse.lua | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ldoc/parse.lua b/ldoc/parse.lua index e695211..d26c3a1 100644 --- a/ldoc/parse.lua +++ b/ldoc/parse.lua @@ -119,9 +119,6 @@ local function parse_file(fname,lang, package) if t == 'comment' then local comment = {} local ldoc_comment,block = lang:start_comment(v) - if ldoc_comment and v:match '%-+$' then - ldoc_comment = false - end if ldoc_comment and block then t,v = lang:grab_block_comment(v,tok) @@ -150,8 +147,11 @@ local function parse_file(fname,lang, package) F:warning("first comment must be a doc comment!") break end - first_comment = false - item_follows, is_local = lang:item_follows(t,v,tok) + if first_comment then + first_comment = false + else + item_follows, is_local = lang:item_follows(t,v,tok) + end if item_follows or comment:find '@'then tags = extract_tags(comment) if doc.project_level(tags.class) then