=================================================================== RCS file: /cvs/mandoc/man_macro.c,v retrieving revision 1.112 retrieving revision 1.114 diff -u -p -r1.112 -r1.114 --- mandoc/man_macro.c 2015/10/06 18:32:19 1.112 +++ mandoc/man_macro.c 2016/01/08 17:48:09 1.114 @@ -1,4 +1,4 @@ -/* $Id: man_macro.c,v 1.112 2015/10/06 18:32:19 schwarze Exp $ */ +/* $Id: man_macro.c,v 1.114 2016/01/08 17:48:09 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons * Copyright (c) 2012, 2013, 2014, 2015 Ingo Schwarze @@ -130,7 +130,7 @@ man_unscope(struct roff_man *man, const struct roff_no man->last = n; n = n->parent; - man_valid_post(man); + man->last->flags |= MAN_VALID; } /* @@ -157,7 +157,7 @@ rew_scope(struct roff_man *man, int tok) /* Preserve empty paragraphs before RS. */ n = man->last; - if (tok == MAN_RS && n->nchild == 0 && + if (tok == MAN_RS && n->child == NULL && (n->tok == MAN_P || n->tok == MAN_PP || n->tok == MAN_LP)) return; @@ -379,28 +379,13 @@ in_line_eoln(MACRO_PROT_ARGS) assert(man->last->type != ROFFT_ROOT); man->next = ROFF_NEXT_SIBLING; - /* - * Rewind our element scope. Note that when TH is pruned, we'll - * be back at the root, so make sure that we don't clobber as - * its sibling. - */ + /* Rewind our element scope. */ for ( ; man->last; man->last = man->last->parent) { + man_state(man, man->last); if (man->last == n) break; - if (man->last->type == ROFFT_ROOT) - break; - man_valid_post(man); } - - assert(man->last); - - /* - * Same here regarding whether we're back at the root. - */ - - if (man->last->type != ROFFT_ROOT) - man_valid_post(man); } void @@ -408,6 +393,7 @@ man_endparse(struct roff_man *man) { man_unscope(man, man->first); + man->flags &= ~MAN_LITERAL; } static int