On Tue, Oct 13, 2026 at 07:29:29PM +0000, Werner LEMBERG wrote:
>
> [9435ceb64dd70b82e427477c5d8a8e6fa65a009f]
>
>
> I fear there are more bugs lurking around in `texindex`.
>
> Please consider the following input.
>
> ```
> \input texinfo
>
> foo
>
> @findex @sortas{\\} \\
> @findex A
> @findex Z
> @findex a
> @findex z
>
> bar
>
> @printindex fn
>
> @bye
> ```
>
> With version 7.1 I get the following index collation in the PDF output.
>
> \ \\
> A a
> A
> Z z
> Z
>
> However, current git yields the following.
>
> A a
> Z z
> A a
> Z z
> \ \\
>
> This looks really broken...
>
>
> Werner
>
I haven't reproduced this, as seen in the output below. I don't have any
idea why it would come out like that.
Can you confirm what version of texinfo.tex you are using as this would
affect the contents of the unsorted test.fn file?
I am running this from inside the "texindex" subdirectory of the git
checkout (in case that is relevant for locating the correct texindex.awk
file):
$ cat test.texi
\input texinfo
foo
@findex @sortas{\\} \\
@findex A
@findex Z
@findex a
@findex z
bar
@printindex fn
@bye
$ pdftex test.texi
This is pdfTeX, Version 3.141592653-2.6-1.40.25 (TeX Live 2023/Debian)
(preloaded format=pdftex)
restricted \write18 enabled.
entering extended mode
(./test.texi (./texinfo.tex Loading texinfo [version 2026-10-10.09]: pdf,
fonts, glyphs, page headings, tables, conditionals, indexing, sectioning, toc,
environments, defuns, macros, cross references, insertions,
(/usr/share/texlive/texmf-dist/tex/generic/epsf/epsf.tex
This is `epsf.tex' v2.7.4 <14 February 2011>
) localization, formatting, microtype, and turning on texinfo input format.)
Writing index file test.fn
(./test.fns) [1{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}] )</usr/shar
e/texlive/texmf-dist/fonts/type1/public/amsfonts/cm/cmbx12.pfb></usr/share/texl
ive/texmf-dist/fonts/type1/public/amsfonts/cm/cmmi9.pfb></usr/share/texlive/tex
mf-dist/fonts/type1/public/amsfonts/cm/cmr10.pfb></usr/share/texlive/texmf-dist
/fonts/type1/public/amsfonts/cm/cmr9.pfb></usr/share/texlive/texmf-dist/fonts/t
ype1/public/amsfonts/cm/cmsy10.pfb></usr/share/texlive/texmf-dist/fonts/type1/p
ublic/amsfonts/cm/cmtt9.pfb>
Output written on test.pdf (1 page, 49810 bytes).
Transcript written on test.log.
$ cat test.fn
@entry{{@indexbackslash}{@indexbackslash}}{1}{@code {@backslashchar
{}@backslashchar {}}}
@entry{A}{1}{@code {A}}
@entry{Z}{1}{@code {Z}}
@entry{a}{1}{@code {a}}
@entry{z}{1}{@code {z}}
$ ./texindex test.fn
$ cat test.fns
@initial {{@indexbackslash}}
@entry{@code {@backslashchar {}@backslashchar {}}}{1}
@initial {A}
@entry{@code {a}}{1}
@entry{@code {A}}{1}
@initial {Z}
@entry{@code {z}}{1}
@entry{@code {Z}}{1}
$