cgnieder / acro

acronyms for LaTeX
LaTeX Project Public License v1.3c
40 stars 9 forks source link

`\printacronyms` fails for nested acronyms if inserted thanks to the `\AtEndDocument` hook #254

Open dbitouze opened 1 year ago

dbitouze commented 1 year ago

[Issue discussed on TeX.SE.]

The compilation of the following MCE:

\documentclass{article}
\usepackage{acro}
\AtEndDocument{\printacronyms}
\DeclareAcronym{gnu}{
  short = GNU ,
  long = GNU's Not Unix
}
\DeclareAcronym{gpl}{
  short = GPL ,
  long = \acs{gnu} General Public License
}
\begin{document}
\ac{gpl}.
\end{document}

fails with the error:

! Missing number, treated as zero.
<to be read again> 
                   \l__acro_pages_list_display_bool 
l.17 \end{document}