aboutsummaryrefslogtreecommitdiff
path: root/xroff.lex
diff options
context:
space:
mode:
Diffstat (limited to 'xroff.lex')
-rw-r--r--xroff.lex4
1 files changed, 3 insertions, 1 deletions
diff --git a/xroff.lex b/xroff.lex
index 6282ca1..72ab379 100644
--- a/xroff.lex
+++ b/xroff.lex
@@ -10,6 +10,7 @@
\\ BEGIN(ESC);
\n BEGIN(NEW);
\<!\[ BEGIN(RAW);
+\<!--.*--> /* Ignore comment. */
^< printf("."); BEGIN(REQ); /* Beginning of file. */
\< printf("\\c\n."); BEGIN(REQ);
. ECHO;
@@ -18,7 +19,8 @@
<NEW>\n /* Ignore consecutive newlines. */
<NEW>\\ printf("\n"); BEGIN(ESC);
-<NEW>\<!\[\n? printf("\n"); BEGIN(RAW);
+<NEW><!\[\n? printf("\n"); BEGIN(RAW);
+<NEW><!--.*--> /* Ignore comment. */
<NEW>< printf("\n."); BEGIN(REQ);
<NEW>\. printf("\n\\&."); BEGIN(0);
<NEW>. printf("\n"); BEGIN(0); REJECT;