Open
Description
With the August 29, 2024, version of AMStoc.pm [b16e12b], the following document
\documentclass{amsbook}
\usepackage{cleveref}
\begin{document}
\frontmatter
\tableofcontents
\mainmatter
\cref{sasakian-three-manifold}
\end{document}
produces an extra paragraph containing
<p>clear@tocstack</p>
It appears that somehow the instances of \@input
in do_finish_toc()
resets the catcode of @
before \@clear@stack
is encountered.
However, in the absence of cleveref, the same thing happens, but clear@tocstack
does not appear in the output.
I'm baffled.