Consider the following MWE:
\documentclass{scrreprt}
\usepackage{textcase}
\RequirePackage{listings}
\usepackage[american]{babel}
\begin{document}
\MakeTextLowercase{A~B}
\end{document}
LaTeX fails with the error
! Undefined control sequence.
<to be read again> az
b
l.9 \MakeTextLowercase{A~B}
?
The error seems to lie in the combination of MakeTextLowercase
, the listings
package and the tilde. Whenever I remove any of these three components, everything works fine. Does anyone have a clue where the problem is?