On Sun, Nov 08, 2026 at 10:37:57AM +0000, Gavin Smith wrote:
> On Thu, Nov 05, 2026 at 12:56:58AM +0000, Heime wrote:
> > 
> > I am using some conditions and get the warning: 
> > 
> > @end ifset should only appear at the beginning of a line
> > 
> > Can the conditionals be made to allow indentation.  Without indentation,
> > the source is not very readable, particularly for nested blocks.
> 
> (switching to bug-texinfo).
> 
> I understand that in TeX, leading whitespace on a line is ignored.  I
> double-checked that leading space before "@end ifset" works fine with TeX.
> 
> Patrice was opposed to copying TeX's handling of leading whitespace in
> texi2any generally, but I see no reason why we couldn't allow whitespace
> in this particular context.

I think that we should be consistent in the Texinfo language.  The line
and block @-commands begin at the start of the line as is said in the
"@-Command Syntax" node of the Texinfo manual.

In practice, texi2any often allows more flexibility, but it may not be
general, as the parsing in ignored blocks may be different from the
general parsing, where it is likely that leading spaces are possible.
Also parsing within @macro body could be different.

> There is specific code to check for this leading space and give a warning.
> It should be easy to remove the code for the warning:

I prefer to give users warning such that they are helped to write
stricter conforming Texinfo code, in case some day the constraint that
line and block @-commands begin at the start of the line becomes
enforced more strictly too.  However I do not object strongly to
removing the warning either.

> This would mean that @end in this one specific context was treated
> similarly to other line commands.
> 
> Does this look OK?

Removing the warning is Ok to me, although I would prefer not, but I
think that we should still be clear that it is non-conforming Texinfo
and that it could break whenever a processor decides to ignore line and
block @-commands that do not start at the beginning of the line.

-- 
Pat

Reply via email to