Closed u-fischer closed 3 years ago
babel assigns \bbl@hymapsel globally in \bbl@switch and locallly in various other places. This can lead to a save size overflow if too many \babel@toc command are made:
\bbl@hymapsel
\bbl@switch
\babel@toc
\documentclass{article} \usepackage[german]{babel} \usepackage{etoolbox} \makeatletter % this patch avoids the overflow: %\patchcmd\bbl@switch{\global\let\bbl@hymapsel\@cclv}{\let\bbl@hymapsel\@cclv}{}{\fail} \makeatother \begin{document} \begingroup \ExplSyntaxOn\makeatletter \int_step_inline:nn{40000}{\babel@toc {german}{}} \ExplSyntaxOff \endgroup blub \end{document}
gives
! TeX capacity exceeded, sorry [save size=80000]. \bbl@exp ...fter \noexpand \csname ##1\endcsname } \edef \bbl@exp@aux {\endgr... l.26 ...ep_inline:nn{40000}{\babel@toc {german}{}}
(This was discovered while discussing the redledpar issue mentioned in issue #108 )
Your fix looks reasonable. I'll study it.
babel assigns
\bbl@hymapsel
globally in\bbl@switch
and locallly in various other places. This can lead to a save size overflow if too many\babel@toc
command are made:gives
(This was discovered while discussing the redledpar issue mentioned in issue #108 )