diff options
Diffstat (limited to 'rst_helpers.lua')
-rw-r--r-- | rst_helpers.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/rst_helpers.lua b/rst_helpers.lua index 49014f4..92f41a2 100644 --- a/rst_helpers.lua +++ b/rst_helpers.lua @@ -593,13 +593,14 @@ do wrapper = Cs(V"nowhitespace"^0 * (Cs(V"wrapme") + V"other")^1), whitespace = S" \t\v" + P"\n" / function() linelength = 0 end, nowhitespace = 1 - V"whitespace", - ignore = P"\\type{" * (1 - P"}")^1 * P"}", - other = Cmt(V"whitespace"^1 * (V"ignore" + (1 - V"whitespace")^1), function(s,i,w) + ignore = P[[\\type{]] * (1 - P"}")^0 * P"}", + other = Cmt(V"whitespace"^0 * (V"ignore" + (1 - V"whitespace")^1), function(s,i,w) linelength = linelength + ulen(w) return true end), wrapme = Cmt(V"whitespace"^1 * (1 - V"whitespace" - V"ignore")^1, function(s,i,w) local lw = ulen(w) + print(w) if linelength + lw > width then linelength = lw return true |