jbezos / enumitem

Customize enumerate, itemize and description
MIT License
45 stars 5 forks source link

TeX capacity exceeded error if \labelenumi is not defined #18

Open u-fischer opened 5 years ago

u-fischer commented 5 years ago

enumitem implicitly assumes that the class defines \labelenumi. Without it, it loops:

\documentclass{article}
\let\labelenumi\undefinedcommand
\usepackage{enumitem}

\begin{document}

    \begin{enumerate}
        \item Bla
        \item Blub
    \end{enumerate}

\end{document}

gives

! TeX capacity exceeded, sorry [grouping levels=255].

A prominent example of such a class is beamer. And while is not recommended to use enumitem with beamer, in some cases people wants to do it anyway and it would be nice if it didn't break then.