[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Texinfo command nesting and syntax checking: nested @ref
From: |
Patrice Dumas |
Subject: |
Re: Texinfo command nesting and syntax checking: nested @ref |
Date: |
Tue, 24 Jan 2023 07:48:29 +0100 |
On Sun, Jan 22, 2023 at 09:19:30PM +0000, Gavin Smith wrote:
> On Sat, Jan 21, 2023 at 03:12:15PM +0100, Patrice Dumas wrote:
> > Please commit, I'll change the perl parser afterwards, it looks very
> > easy to implement. I have a commit related to source marks ready that I
> > can commit before or after changing the perl parser for this change,
> > actually.
>
> Thanks for updating the perl parser.
>
> I was thinking the nesting warning for @ref could be removed now it is
> redundant: for
>
> @ref{aaa@ref{bbb}}
>
> there are two warnings:
>
> test.texi:6: warning: @ref should not appear in @ref
> test.texi:6: warning: @ref should not appear anywhere inside cross-reference
>
> However, this appears to be also an issue for all of the commands
> that are marked "contain_simple_text" in command_data.txt. Would
> it make sense to replace the nesting_context.xref counter with
> a nesting_context.simple_text counter and use it for all of the
> contain_simple_text commands?
I think so. The implementation I had in mind replaced
check_valid_nesting by a check on the whole command stack. Replacing
check_valid_nesting by a forwarding of the nesting context is equally good.
> Perhaps we should also keep a stack of which commands incremented this
> counter so we can report the invalid nesting in an error message?
It is a necessity, in my opinion.
--
Pat
- Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/17
- Re: Texinfo command nesting and syntax checking: nested @ref, Patrice Dumas, 2023/01/18
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/18
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/18
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/18
- Re: Texinfo command nesting and syntax checking: nested @ref, Patrice Dumas, 2023/01/18
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/21
- Re: Texinfo command nesting and syntax checking: nested @ref, Patrice Dumas, 2023/01/21
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/22
- Re: Texinfo command nesting and syntax checking: nested @ref,
Patrice Dumas <=
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/29
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/30
- Re: Texinfo command nesting and syntax checking: nested @ref, Patrice Dumas, 2023/01/30
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/23
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/24
- Re: Texinfo command nesting and syntax checking: nested @ref, Gavin Smith, 2023/01/25
Name of "simple text", Gavin Smith, 2023/01/25