=================================================================== RCS file: /cvs/mandoc/mdoc_macro.c,v retrieving revision 1.24 retrieving revision 1.27 diff -u -p -r1.24 -r1.27 --- mandoc/mdoc_macro.c 2009/07/19 21:26:27 1.24 +++ mandoc/mdoc_macro.c 2009/07/25 16:03:03 1.27 @@ -1,4 +1,4 @@ -/* $Id: mdoc_macro.c,v 1.24 2009/07/19 21:26:27 kristaps Exp $ */ +/* $Id: mdoc_macro.c,v 1.27 2009/07/25 16:03:03 kristaps Exp $ */ /* * Copyright (c) 2008, 2009 Kristaps Dzonsons * @@ -681,7 +681,7 @@ blk_exp_close(MACRO_PROT_ARGS) mdoc->next = MDOC_NEXT_CHILD; } - for (lastarg = ppos, flushed = j = 0; ; j++) { + for (flushed = j = 0; ; j++) { lastarg = *pos; if (j == maxargs && ! flushed) { @@ -742,13 +742,17 @@ in_line(MACRO_PROT_ARGS) * usually because of reserved words) to squeak by. */ switch (tok) { - case (MDOC_Nm): + case (MDOC_An): /* FALLTHROUGH */ + case (MDOC_Ar): + /* FALLTHROUGH */ case (MDOC_Fl): /* FALLTHROUGH */ case (MDOC_Lk): /* FALLTHROUGH */ - case (MDOC_Ar): + case (MDOC_Nm): + /* FALLTHROUGH */ + case (MDOC_Pa): nc = 1; break; default: @@ -756,7 +760,7 @@ in_line(MACRO_PROT_ARGS) break; } - for (la = ppos, arg = NULL;; ) { + for (arg = NULL;; ) { la = *pos; c = mdoc_argv(mdoc, line, tok, &arg, pos, buf); @@ -1042,7 +1046,7 @@ blk_part_imp(MACRO_PROT_ARGS) /* XXX - no known argument macros. */ - for (lastarg = ppos;; ) { + for (;;) { lastarg = *pos; c = mdoc_args(mdoc, line, pos, buf, tok, &p); assert(ARGS_PHRASE != c); @@ -1103,7 +1107,6 @@ blk_part_exp(MACRO_PROT_ARGS) int lastarg, flushed, j, c, maxargs; char *p; - lastarg = ppos; flushed = 0; /* @@ -1239,7 +1242,7 @@ in_line_argn(MACRO_PROT_ARGS) break; } - for (lastarg = ppos, arg = NULL;; ) { + for (arg = NULL;; ) { lastarg = *pos; c = mdoc_argv(mdoc, line, tok, &arg, pos, buf);