[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: In an @example, @comment at EOL swallows the following newline.
From: |
Gavin Smith |
Subject: |
Re: In an @example, @comment at EOL swallows the following newline. |
Date: |
Mon, 1 Jan 2018 22:23:23 +0000 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
On Mon, Jan 01, 2018 at 05:55:52PM +0000, Alan Mackenzie wrote:
> The actual source in cc-mode.texi which showed up the bug was indeed in
> a macro, namely:
>
> @macro hereFn{func}
> <- @address@hidden
> @end macro
>
> . This macro was committed on 2003-05-12. The @c at EOL2 looks like a
> workaround for some glitch in an earlier version of makeinfo. (As a
> matter of interest, makeinfo 4.13 builds the source correctly, whether
> or not the "@c" is present.).
>
> This workaround could be present in a lot of files.texi that were being
> actively modified around 15 years ago. Again, would it be possible to
> output a warning for this situation, and possibly document it in
> texinfo's own documentation?
>
> Thanks!
I ran a test with a very old version of texinfo.tex, the version in
Texinfo 3.0, (texinfo.tex itself reports a version of 2.108) and the
newline disappears from the end of the comment too:
\input texinfo
@setfilename
@example
@group
main (int,
char address@hidden some comment
)
@end group
@end example
@bye
This is somewhat beside the point because the @c is appearing through a
macro (which wasn't supported in this old version of texinfo.tex). I tried
the following with the texinfo.tex in Texinfo 4.13:
\input texinfo
@setfilename
@macro m
<-- address@hidden somecomment
@end macro
@example
@group
main (int,
char address@hidden
)
@end group
@end example
@bye
and the expected output is obtained. Somehow when @c is used directly
in place of @m{} it is joined with the following line.
I tried the same with the most recent version of texinfo.tex
(2017-12-26.21) and the same happens: with
@example
@group
main (int,
char address@hidden
char address@hidden
)
@end group
@end example
the lines are not joined after the @m{} but they are joined after the
@c.
There could be a case for changing makeinfo to be consistent with
texinfo.tex, provided we can work out what texinfo.tex is doing.
- Re: In an @example, @comment at EOL swallows the following newline., Gavin Smith, 2018/01/01
- Re: In an @example, @comment at EOL swallows the following newline., Eli Zaretskii, 2018/01/01
- Re: In an @example, @comment at EOL swallows the following newline.,
Gavin Smith <=
- Re: In an @example, @comment at EOL swallows the following newline., Gavin Smith, 2018/01/01
- Re: In an @example, @comment at EOL swallows the following newline., Eli Zaretskii, 2018/01/02