muzimuzhi / thmtools

New home for LaTeX package bundle thmtools
LaTeX Project Public License v1.3c
16 stars 3 forks source link

aliasctr: `\@ifdefinable` accepts a cs, not csname #28

Closed muzimuzhi closed 2 years ago

muzimuzhi commented 2 years ago
diff --git a/source/aliasctr.dtx b/source/aliasctr.dtx
index 20546f8..2d88038 100644
--- a/source/aliasctr.dtx
+++ b/source/aliasctr.dtx
@@ -79,7 +79,7 @@
       \csname ##2\endcsname
     }%
     \@ifundefined{c@#2}{\@nocounterr{#2}}{%
-      \@ifdefinable{c@#1}{%
+      \expandafter\@ifdefinable\csname c@#1\endcsname{%
 %    \end{macrocode}
 %    Four values make a counter foo:
 %    \begin{itemize}