summaryrefslogtreecommitdiffstatshomepage
path: root/mdoc.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-06-16 19:13:28 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-06-16 19:13:28 +0000
commit632038c8c98f1c408bb368edf910b849f186dc8a (patch)
tree000479224756a6b4a7749394e9208b7308c220ab /mdoc.c
parentb06a75d0798f3ff62d04b3ade52cf34a4ff94613 (diff)
downloadmandoc-632038c8c98f1c408bb368edf910b849f186dc8a.tar.gz
mandoc-632038c8c98f1c408bb368edf910b849f186dc8a.tar.zst
mandoc-632038c8c98f1c408bb368edf910b849f186dc8a.zip
Modernised comment handling: text following \" is thrown away before
either parser is invoked. Single-dot lines correctly handled. This confirms with both new- and old-groff. "Comment" subsection added to mdoc.7 and man.7.
Diffstat (limited to 'mdoc.c')
-rw-r--r--mdoc.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/mdoc.c b/mdoc.c
index c1d07afa..3808f144 100644
--- a/mdoc.c
+++ b/mdoc.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc.c,v 1.80 2009/06/15 10:36:01 kristaps Exp $ */
+/* $Id: mdoc.c,v 1.81 2009/06/16 19:13:28 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -657,7 +657,7 @@ parsemacro(struct mdoc *m, int ln, char *buf)
int i, c;
char mac[5];
- /* Comments and empties are quickly ignored. */
+ /* Empty lines are ignored. */
if (0 == buf[1])
return(1);
@@ -671,10 +671,6 @@ parsemacro(struct mdoc *m, int ln, char *buf)
return(perr(m, ln, 1, ESPACE));
}
- if (buf[1] && '\\' == buf[1])
- if (buf[2] && '\"' == buf[2])
- return(1);
-
/* Copy the first word into a nil-terminated buffer. */
for (i = 1; i < 5; i++) {