Hi!

The backslash-period escape sequence in groff doesn't work as described in 
documentation.

Manual page:
\.     An uninterpreted dot (period), even at start of line.

Minimal reproducer:
$ groff -wmac -Tascii <<< '\.foo'
<standard input>:1: warning: macro `foo' not defined

Original report in Fedora:
https://bugzilla.redhat.com/show_bug.cgi?id=682857

I'm attaching a proposed patch. But I suppose there is a better way of fixing 
it. This looks a little bit like a workaround. It is just the easiest way with 
the least modifications of the code.

Jan


--
Jan Včelák
Base Operating Systems Brno
Red Hat Inc.
--- groff-1.21/src/roff/troff/input.cpp	2010-12-31 08:33:08.000000000 +0100
+++ groff-1.21.period/src/roff/troff/input.cpp	2011-03-21 19:31:40.234710613 +0100
@@ -1932,6 +1932,10 @@
 	goto ESCAPE_HYPHEN;
       case '_':
 	goto ESCAPE_UNDERSCORE;
+      case '.':
+	type = TOKEN_SPECIAL;
+	nm = symbol("char46");
+	return;
       case '%':
 	goto ESCAPE_PERCENT;
       case ' ':
_______________________________________________
bug-groff mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-groff

Reply via email to