From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp-2.sys.kth.se (smtp-2.sys.kth.se [130.237.32.160]) by krisdoz.my.domain (8.14.3/8.14.3) with ESMTP id p4I9atoo024300 for ; Wed, 18 May 2011 05:36:56 -0400 (EDT) Received: from mailscan-1.sys.kth.se (mailscan-1.sys.kth.se [130.237.32.91]) by smtp-2.sys.kth.se (Postfix) with ESMTP id 18B9914DCDE for ; Wed, 18 May 2011 11:36:50 +0200 (CEST) X-Virus-Scanned: by amavisd-new at kth.se Received: from smtp-2.sys.kth.se ([130.237.32.160]) by mailscan-1.sys.kth.se (mailscan-1.sys.kth.se [130.237.32.91]) (amavisd-new, port 10024) with LMTP id OG42RFeXNiOJ for ; Wed, 18 May 2011 11:36:49 +0200 (CEST) X-KTH-Auth: kristaps [213.103.216.43] X-KTH-mail-from: kristaps@bsd.lv X-KTH-rcpt-to: discuss@mdocml.bsd.lv Received: from macky.local (s213-103-216-43.cust.tele2.se [213.103.216.43]) by smtp-2.sys.kth.se (Postfix) with ESMTP id E09E414DCB1 for ; Wed, 18 May 2011 11:36:48 +0200 (CEST) Message-ID: <4DD3932F.5020902@bsd.lv> Date: Wed, 18 May 2011 11:36:47 +0200 From: Kristaps Dzonsons User-Agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.17) Gecko/20110414 Thunderbird/3.1.10 X-Mailinglist: mdocml-discuss Reply-To: discuss@mdocml.bsd.lv MIME-Version: 1.0 To: discuss@mdocml.bsd.lv Subject: Re: tbl example - what should be fixed? References: <20110516111854.GA58664@procyon.xvoid.org> <4DD27469.5070505@bsd.lv> <20110518063023.GE1321@procyon.xvoid.org> In-Reply-To: <20110518063023.GE1321@procyon.xvoid.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 18/05/2011 08:30, Yuri Pankov wrote: > On Tue, May 17, 2011 at 03:13:13PM +0200, Kristaps Dzonsons wrote: >>> We have a lot of manpages having the similar looking tables: >>> .TS >>> tab() box; >>> cw(2.75i) |cw(2.75i) >>> lw(2.75i) |lw(2.75i) >>> . >>> TYPEVALUE >>> _ >>> Type1Value1 >>> _ >>> Type2Value2 >>> .TE >>> >>> Output of -Tlint: >>> tbl.example:2:5: ERROR: skipping bad character: ignoring byte >>> tbl.example:2:6: ERROR: bad table syntax >>> tbl.example:3:12: ERROR: bad table layout >>> tbl.example:4:12: ERROR: bad table layout >>> tbl.example:6:15: ERROR: skipping bad character: ignoring byte >>> tbl.example:6:4: ERROR: bad table layout >>> tbl.example:8:4: ERROR: skipping bad character: ignoring byte >>> tbl.example:8:2: ERROR: bad table layout >>> tbl.example:10:20: ERROR: skipping bad character: ignoring byte >>> tbl.example:10:1: ERROR: bad table layout >>> tbl.example:1:1: ERROR: no table data cells specified >>> >>> >>> My questions is, is there anything that could/should be fixed/improved >>> in tbl parser, or all of the errors are 100% correct and should be fixed >>> in the manpages? >> >> Yuri, >> >> From mdoc.7: >> >> LANGUAGE SYNTAX >> mdoc documents may contain only graphable 7-bit ASCII >> characters, the space character, and, in certain circumstances, >> the tab character. >> >> The tbl.7 manuals says the same. But you have non-ASCII characters in >> the input. groff is probably letting you get away with this by simply >> reading through the binary to the ')', but mandoc throws away the binary >> characters before parsing. >> >> Second, you did raise a bug! I was looking for modifiers for the >> vertical bar, i.e., a|b -> error. I just committed a fix for this. >> >> The stand-alone period is another problem. groff *should* ignore it by >> its own definition of a no-op macro. But as it occurs in a tbl context, >> it's different? Blje... For now, just put the period on the same line >> as the last macro. > > Thanks, Kristaps. I was just making sure what I should fix locally (a > simple sed script took care of it..) Yuri, great! The multibyte char is something that can be solved in different ways, but I've added an entry to the TODO regarding the standalone period, which should be implemented if you're seeing it in the wild. Thanks, Kristaps -- To unsubscribe send an email to discuss+unsubscribe@mdocml.bsd.lv