Compiling the following file
\documentclass{article}
% \usepackage{xcolor} % this guy does the highlighing work
\usepackage{soul}
\begin{document}
\hl{cf.\ ??}
\end{document}
with pdflatex
produces the error
! Package soul Error: Reconstruction failed.
See the soul package documentation for explanation.
Type H <return> for immediate help.
...
l.5 \hl{cf.\ ??}
? Q
(In the above, xcolor is not loaded for the purpose of constructing a minimal non-compiling example.)
Of course, workarounds exist, such as replacing .\
with .\@
, or putting the sucker into an \mbox
. Still, I wonder whether one could have a better automatic solution in first place. Perhaps, a better highlighting package?
\emph{..}
or, for stronger emphasis\textbf{..}
instead.\hl
doesn't really underline, but it uses a background color whencolor
orxcolor
is loaded.\
to\@
first as you wrote. I just wanted to see what\hl
does without studying the manual.