[BACK]Return to man.out_lint CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc / regress / roff / args

File: [cvsweb.bsd.lv] / mandoc / regress / roff / args / man.out_lint (download)

Revision 1.6, Fri Jun 3 12:15:56 2022 UTC (2 years ago) by schwarze
Branch: MAIN
CVS Tags: HEAD
Changes since 1.5: +1 -1 lines

During identifier parsing, handle undefined escape sequences
in the same way as groff:
* \\ is always reduced to \
* \. is always reduced to .
* other undefined escape sequences are usually reduced to the escape name,
for example \G to G, except during the expansion of expanding escape
sequences having the standard argument form (in particular \* and \n),
in which case the backslash is preserved literally.

Yes, this is confusing indeed.
For example, the following have the same meaning:
* .ds \.   and   .ds .     which is not the same as   .ds \\.
* \*[\.]   and   \*[.]     which is not the same as   \*[\\.]
* .ds \G   and   .ds G     which is not the same as   .ds \\G
* \*[\G]   and   \*[\\G]   which is not the same as   \*[G]   <- sic!

To feel less dirty, have a leaning toothpick, if you are so inclined.

This patch also slightly improves the string shown by the "escaped
character not allowed in a name" error message.

mandoc: man.in:35:13: STYLE: whitespace at end of input line
mandoc: man.in:39:14: STYLE: whitespace at end of input line
mandoc: man.in:43:15: STYLE: whitespace at end of input line
mandoc: man.in:83:25: STYLE: whitespace at end of input line
mandoc: man.in:87:26: STYLE: whitespace at end of input line
mandoc: man.in:91:27: STYLE: whitespace at end of input line
mandoc: man.in:104:5: STYLE: unterminated quoted argument
mandoc: man.in:107:9: STYLE: unterminated quoted argument
mandoc: man.in:131:1: ERROR: escaped character not allowed in a name: IB\(lq