Skip to content

Commit

Permalink
Remove use of letltxmacro
Browse files Browse the repository at this point in the history
  • Loading branch information
MLopez-Ibanez committed May 17, 2024
1 parent 3b389d9 commit c6d4c60
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
11 changes: 5 additions & 6 deletions newrevisor.sty
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
%
% See full documentation: https://github.com/MLopez-Ibanez/revision
\RequirePackage{iftex}
\RequirePackage{letltxmacro} % Replace with https://anorien.csc.warwick.ac.uk/mirrors/CTAN/macros/latex/contrib/l3packages/xparse.pdf
\RequirePackage{etoolbox} % \csuse \ifdef
\RequirePackage{xparse}
\PassOptionsToPackage{dvipsnames}{xcolor}
Expand Down Expand Up @@ -96,19 +95,19 @@
}
\NewDocumentCommand{\mysout}{+m}{%
% Force inline comments when deleting text, otherwise we get weird errors.
\LetLtxMacro\origrevcomment\newrevisor@RevComment
\NewCommandCopy\origrevcomment\newrevisor@RevComment
\let\newrevisor@RevComment\newrevisor@RevInlineComment
\LetLtxMacro\origref\ref% Sometimes \ref produces Extra }, or forgotten \endgroup.
\NewCommandCopy\origref\ref% Sometimes \ref produces Extra }, or forgotten \endgroup.
\renewcommand{\ref}[1]{\mbox{\origref{##1}}}%
\LetLtxMacro\origcite\cite%
\NewCommandCopy\origcite\cite%
\renewcommand{\cite}[2][]{\mbox{\origcite[##1]{##2}}}%
%\makeatletter%
\@ifundefined{citet}{}{%
\LetLtxMacro\origcitet\citet%
\NewCommandCopy\origcitet\citet%
\renewcommand{\citet}[2][]{\mbox{\origcitet[##1]{##2}}}%
}%
\@ifundefined{citep}{}{%
\LetLtxMacro\origcitep\citep%
\NewCommandCopy\origcitep\citep%
\renewcommand{\citep}[2][]{\mbox{\origcitep[##1]{##2}}}%
}%
% \makeatother%
Expand Down
2 changes: 1 addition & 1 deletion test
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ check_snapshot() {
fi
diff -q ${old} ${new} > /dev/null
if [ $? -ne 0 ]; then
echo "Error: ${old} and ${new} are different"
echo "Error: ${old} and ${new} are different (use diffimg to visualize the differences)"
ERROR=1
else
rm -f ${new}
Expand Down

0 comments on commit c6d4c60

Please sign in to comment.