Subject: Stack overflow in reftex-parse-all
From: Nils Kanning <[email-masked]>
To: [email-masked]
Date: Fri, 11 Dec 2015 22:03:24 +0100
List-Id: <debbugs-submit.debbugs.gnu.org>

Dear all,

I encounter the error "Stack overflow in regexp matcher" if I apply the
function reftex-parse-all to the following file:

\documentclass{article}
\begin{document} 
[\}
foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo
...
foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo foo
\end{document}

Here ... stands for 500 copies of the line above. The file can be
compiled successfully with pdflatex.

I am using the Debian packages emacs24 24.5+1-3 and auctex 11.88-1.1.
The same error also occurs with different versions.

In case you are wondering, the non-matching brackets [\} appear for
example in physics as so-called "super Lie brackets".

Best
Nils