15 years ago, I was using LaTeX on a daily basis for writing my dissertation, articles, and presentations. I used the beamer
package to create both slides and notes with the same source for several courses I taught. I am planning on giving a presentation soon and since I am lazy, I wanted to copy/paste an old presentation to get started. I was saddened to discover that the 12 year old LaTeX file I found would not compile, but gave me this strange error.
! Undefined control sequence. l.1 \beamer@endinputifotherversion
I figured that there must have been some backwards incompatible change in LaTeX / beamer in the last 12 years. I tried several other files, and found the same thing. Then I opened up the documentation using texdoc beamer
and found mention of an example file included in the package called conference-ornate-20min.en.tex
. I tried compiling this example file, and it worked! I also found an old near-copy of the same file called example.tex
on my computer. This one would not compile. I started diffing and noticed that the old one used syntax like:
\begin{frame}
\frametitle{title of this slide}
\end{frame}
while the newer example file used
\begin{frame}{title of this slide}
\end{frame}
I changed all of these in the old file, but it would still not compile. What gives? I decided to get more aggressive, and renamed the old file, and tried again, and suddenly it worked. Huh? It turns out I had some old intermediate files lying around, which LaTeX was trying to use, and apparently the format of these intermediate files has changed in the last 12 years. I tested out this theory with a different file, and also had success. So if you run into weird errors trying to compile old LaTeX documents, make sure to delete all the intermediate files like .toc
, .aux
, etc. You probably only need the .tex
file.
I think it is really remarkable that the current LaTeX and beamer still work with 12 year old files. I don’t think there are many other tools which can boast that sort of backwards compatibility.
Don’t know much about LaTeX? Maybe you would find my article why LaTeX interesting.