[Tex/LaTex] fontspec + package “accents” (bezos) = “! LaTeX Error: Command `\acute’ already defined.”

accentsfontspecxetex

I am trying to define the "less-than" Symbol "<" as a math-accent via the "accents" package of Javier Bezos.

\documentclass{minimal}
\usepackage{fontspec}
\usepackage{accents}

\begin{document}

$\accentset{<}{A}$

\end{document}

However, I get the following error message:

! LaTeX Error: Command `\acute' already defined.

Leaving out the fontspec-package does the trick. Unfortunately, I need it for the rest of the document. Is there a way to get around this problem?

Best Answer

It works with the no-math option for fontspec, which suppresses fontspec maths adjustments. This is also the behavior if a maths font package such as mathpazo or unicode-math is loaded, so the error would not occur then.

\documentclass{minimal}
\usepackage[no-math]{fontspec}
\usepackage{accents}
\begin{document}
$\accentset{>}{A}$
\end{document}

accent example