From fdfa9ac6e8b17fee003a4333fd6d4767d6b492fb Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Sat, 13 Dec 2014 13:14:39 +0000 Subject: [PATCH] Fix a regression found by Carsten dot Kunze at arcor dot de: Do not show bogus quotes when .Bl -column phrases are quoted. --- TODO | 13 +++++++++++-- mdoc_macro.c | 8 +++----- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/TODO b/TODO index 7a401273..b213e8b9 100644 --- a/TODO +++ b/TODO @@ -1,6 +1,6 @@ ************************************************************************ * Official mandoc TODO. -* $Id: TODO,v 1.194 2014/12/10 21:54:13 schwarze Exp $ +* $Id: TODO,v 1.195 2014/12/13 13:14:39 schwarze Exp $ ************************************************************************ Many issues are annotated for difficulty as follows: @@ -299,9 +299,18 @@ are mere guesses, and some may be wrong. * formatting issues: ugly output ************************************************************************ -- a column list with blank `Ta' cells triggers a spurrious +- revisit empty in-line macros + look at the difference between "Em x Em ." and "Sq x Em ." + Carsten Kunze Fri, 12 Dec 2014 00:15:41 +0100 + loc *** exist *** algo *** size * imp ** + +- a column list with blank `Ta' cells triggers a spurious start-with-whitespace printing of a newline +- In .Bl -column, .It a"bc" + shows the quotes in groff, but not in mandoc + loc * exist *** algo ** size * imp ** + - In .Bl -column, .It Em AuthenticationKey Length ought to render "Key Length" with emphasis, too, diff --git a/mdoc_macro.c b/mdoc_macro.c index 68b6a129..b354e540 100644 --- a/mdoc_macro.c +++ b/mdoc_macro.c @@ -1,4 +1,4 @@ -/* $Id: mdoc_macro.c,v 1.156 2014/11/30 05:29:00 schwarze Exp $ */ +/* $Id: mdoc_macro.c,v 1.157 2014/12/13 13:14:39 schwarze Exp $ */ /* * Copyright (c) 2008-2012 Kristaps Dzonsons * Copyright (c) 2010, 2012, 2013, 2014 Ingo Schwarze @@ -672,11 +672,9 @@ macro_or_word(MACRO_PROT_ARGS, int parsed) p = buf + ppos; ntok = MDOC_MAX; - if (mdoc->flags & MDOC_PHRASELIT) - /* nothing */; - else if (*p == '"') + if (*p == '"') p++; - else if (parsed) + else if (parsed && ! (mdoc->flags & MDOC_PHRASELIT)) ntok = lookup(mdoc, tok, line, ppos, p); if (ntok == MDOC_MAX) { -- 2.47.1