josephwright / etoolbox

Tool-box for LaTeX programmers using e-TeX
LaTeX Project Public License v1.3c
41 stars 7 forks source link

Add support for \NewCommandCopy #28

Closed PhelypeOleinik closed 4 years ago

PhelypeOleinik commented 4 years ago

This pull request adds \NewCommandCopy support for \newrobustcmd-defined commands. Two macros are defined here:

These macros do not work as a general-purpose “is this macro defined with \newrobustcmd, then copy it” because they may fail for macros with parameters, as other conditionals of the same type implemented in the LaTeX kernel. Thus the choice to make them internal macros.