From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from localhost (fantadrom.bsd.lv [local]); by fantadrom.bsd.lv (OpenSMTPD) with ESMTPA id 5b229a6f; for ; Fri, 23 Jan 2015 21:42:19 -0500 (EST) Date: Fri, 23 Jan 2015 21:42:19 -0500 (EST) Message-Id: <10485548787424985140.enqueue@fantadrom.bsd.lv> X-Mailinglist: mdocml-source Reply-To: source@mdocml.bsd.lv MIME-Version: 1.0 From: schwarze@mdocml.bsd.lv To: source@mdocml.bsd.lv Subject: mdocml: Strangely, ignoring the roff(7) .na request was implemented in X-Mailer: activitymail 1.26, http://search.cpan.org/dist/activitymail/ Content-Type: text/plain; charset=utf-8 Log Message: ----------- Strangely, ignoring the roff(7) .na request was implemented in the man(7) parser. Simplify the code by moving it into the roff(7) parser, also making it work for mdoc(7). Modified Files: -------------- mdocml: man.7 man.c man.h man_html.c man_macro.c man_term.c man_validate.c roff.c Revision Data ------------- Index: man_term.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/man_term.c,v retrieving revision 1.165 retrieving revision 1.166 diff -Lman_term.c -Lman_term.c -u -p -r1.165 -r1.166 --- man_term.c +++ man_term.c @@ -114,7 +114,6 @@ static const struct termact termacts[MAN { pre_I, NULL, 0 }, /* I */ { pre_alternate, NULL, 0 }, /* IR */ { pre_alternate, NULL, 0 }, /* RI */ - { pre_ign, NULL, MAN_NOTEXT }, /* na */ { pre_sp, NULL, MAN_NOTEXT }, /* sp */ { pre_literal, NULL, 0 }, /* nf */ { pre_literal, NULL, 0 }, /* fi */ Index: roff.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/roff.c,v retrieving revision 1.255 retrieving revision 1.256 diff -Lroff.c -Lroff.c -u -p -r1.255 -r1.256 --- roff.c +++ roff.c @@ -179,7 +179,7 @@ enum rofft { ROFF_minss, ROFF_mk, ROFF_mso, - /* MAN_na; ignored in mdoc(7) */ + ROFF_na, ROFF_ne, /* MAN_nf; ignored in mdoc(7) */ ROFF_nh, @@ -580,6 +580,7 @@ static struct roffmac roffs[ROFF_MAX] = { "minss", roff_line_ignore, NULL, NULL, 0, NULL }, { "mk", roff_line_ignore, NULL, NULL, 0, NULL }, { "mso", roff_insec, NULL, NULL, 0, NULL }, + { "na", roff_line_ignore, NULL, NULL, 0, NULL }, { "ne", roff_line_ignore, NULL, NULL, 0, NULL }, { "nh", roff_line_ignore, NULL, NULL, 0, NULL }, { "nhychar", roff_line_ignore, NULL, NULL, 0, NULL }, Index: man_macro.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/man_macro.c,v retrieving revision 1.93 retrieving revision 1.94 diff -Lman_macro.c -Lman_macro.c -u -p -r1.93 -r1.94 --- man_macro.c +++ man_macro.c @@ -72,7 +72,6 @@ const struct man_macro __man_macros[MAN_ { in_line_eoln, MAN_SCOPED | MAN_JOIN }, /* I */ { in_line_eoln, 0 }, /* IR */ { in_line_eoln, 0 }, /* RI */ - { in_line_eoln, MAN_NSCOPED }, /* na */ { in_line_eoln, MAN_NSCOPED }, /* sp */ { in_line_eoln, MAN_BSCOPE }, /* nf */ { in_line_eoln, MAN_BSCOPE }, /* fi */ Index: man.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/man.c,v retrieving revision 1.147 retrieving revision 1.148 diff -Lman.c -Lman.c -u -p -r1.147 -r1.148 --- man.c +++ man.c @@ -39,7 +39,7 @@ const char *const __man_macronames[MAN_M "IP", "HP", "SM", "SB", "BI", "IB", "BR", "RB", "R", "B", "I", "IR", - "RI", "na", "sp", "nf", + "RI", "sp", "nf", "fi", "RE", "RS", "DT", "UC", "PD", "AT", "in", "ft", "OP", "EX", "EE", Index: man.h =================================================================== RCS file: /home/cvs/mdocml/mdocml/man.h,v retrieving revision 1.68 retrieving revision 1.69 diff -Lman.h -Lman.h -u -p -r1.68 -r1.69 --- man.h +++ man.h @@ -38,7 +38,6 @@ enum mant { MAN_I, MAN_IR, MAN_RI, - MAN_na, MAN_sp, MAN_nf, MAN_fi, Index: man.7 =================================================================== RCS file: /home/cvs/mdocml/mdocml/man.7,v retrieving revision 1.130 retrieving revision 1.131 diff -Lman.7 -Lman.7 -u -p -r1.130 -r1.131 --- man.7 +++ man.7 @@ -727,8 +727,6 @@ If is signed, the new offset is relative. Otherwise, it is absolute. This value is reset upon the next paragraph, section, or sub-section. -.Ss \&na -Don't align to the right margin. .Ss \&nf Begin literal mode: all subsequent free-form lines have their end of line boundaries preserved. @@ -780,10 +778,9 @@ is equivalent to If next-line macros are invoked consecutively, only the last is used. If a next-line macro is followed by a non-next-line macro, an error is raised, except for -.Sx \&br , -.Sx \&sp , +.Sx \&br and -.Sx \&na . +.Sx \&sp . .Pp The syntax is as follows: .Bd -literal -offset indent @@ -814,7 +811,6 @@ The syntax is as follows: .It Sx \&br Ta 0 Ta current Ta compat .It Sx \&fi Ta 0 Ta current Ta compat .It Sx \&in Ta 1 Ta current Ta compat -.It Sx \&na Ta 0 Ta current Ta compat .It Sx \&nf Ta 0 Ta current Ta compat .It Sx \&sp Ta 1 Ta current Ta compat .El Index: man_validate.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/man_validate.c,v retrieving revision 1.108 retrieving revision 1.109 diff -Lman_validate.c -Lman_validate.c -u -p -r1.108 -r1.109 --- man_validate.c +++ man_validate.c @@ -79,7 +79,6 @@ static v_check man_valids[MAN_MAX] = { NULL, /* I */ NULL, /* IR */ NULL, /* RI */ - check_eq0, /* na */ post_vs, /* sp */ post_nf, /* nf */ post_fi, /* fi */ Index: man_html.c =================================================================== RCS file: /home/cvs/mdocml/mdocml/man_html.c,v retrieving revision 1.108 retrieving revision 1.109 diff -Lman_html.c -Lman_html.c -u -p -r1.108 -r1.109 --- man_html.c +++ man_html.c @@ -100,7 +100,6 @@ static const struct htmlman mans[MAN_MAX { man_I_pre, NULL }, /* I */ { man_alt_pre, NULL }, /* IR */ { man_alt_pre, NULL }, /* RI */ - { man_ign_pre, NULL }, /* na */ { man_br_pre, NULL }, /* sp */ { man_literal_pre, NULL }, /* nf */ { man_literal_pre, NULL }, /* fi */ -- To unsubscribe send an email to source+unsubscribe@mdocml.bsd.lv