"G. Branden Robinson" <g.branden.robin...@gmail.com> writes:
> For the (neutral) double quote, you have recourse to an obscure > syntactical feature of AT&T 'troff'. Because a double quote can begin a > macro argument, the formatter keeps track of whether the current > argument was started thus, and doesn't require a space after the double > quote that ends it.(2) (*note Calling Macros-Footnote-2::) In the > argument list to a macro, a double quote that _isn't_ preceded by a > space _doesn't_ start a macro argument. If not preceded by a double > quote that began an argument, this double quote becomes part of the > argument. Futhermore, within a quoted argument, a pair of adjacent > double quotes becomes a literal double quote. Incidentally, the rules for the second argument to .ds appear to not follow the normal rules for macro arguments. .ds C` "" defines \*(C` to a single double-quote, but: .ds C` """" defines \*(C` to """, not to " as one might expect if that were interpreted as a quoted argument and then adjacent doublequotes become a literal double quote. So far as I can tell, the correct rule for escaping the second argument to .ds is that you should double any *leading* double quote, but leave all the other double quotes alone. .ds C` " appears to define \*(C` to the empty string. (I'm not sure where this all might be documented.) -- Russ Allbery (ea...@eyrie.org) <https://www.eyrie.org/~eagle/>