diff options
author | Karl Berry <karl@freefriends.org> | 2010-09-12 22:39:54 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-09-12 22:39:54 +0000 |
commit | a3600660f91c0e808336c01cb388e7b357c289f4 (patch) | |
tree | e6cd673d076b75024e802977d53936d29be9d69b /Master/texmf-dist/tex/latex/etoolbox | |
parent | a39620ec6b8037d1562645b4b61f995a0cb52eac (diff) |
etoolbox 2.0a (12sep10)
git-svn-id: svn://tug.org/texlive/trunk@19683 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/etoolbox')
-rw-r--r-- | Master/texmf-dist/tex/latex/etoolbox/etoolbox.def | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/etoolbox/etoolbox.sty | 51 |
2 files changed, 29 insertions, 26 deletions
diff --git a/Master/texmf-dist/tex/latex/etoolbox/etoolbox.def b/Master/texmf-dist/tex/latex/etoolbox/etoolbox.def index d3e0dbdf99d..a14b8fd00c6 100644 --- a/Master/texmf-dist/tex/latex/etoolbox/etoolbox.def +++ b/Master/texmf-dist/tex/latex/etoolbox/etoolbox.def @@ -1,7 +1,7 @@ -% $Id: etoolbox.def,v 2.0 2010/08/21 17:07:46 lehman stable $ +% $Id: etoolbox.def,v 2.0a 2010/09/12 11:42:38 lehman stable $ \ProvidesFile{etoolbox.def} -[\csname etb@rcsid\endcsname $Id: etoolbox.def,v 2.0 2010/08/21 17:07:46 lehman stable $ +[\csname etb@rcsid\endcsname $Id: etoolbox.def,v 2.0a 2010/09/12 11:42:38 lehman stable $ etoolbox debug messages] \begingroup diff --git a/Master/texmf-dist/tex/latex/etoolbox/etoolbox.sty b/Master/texmf-dist/tex/latex/etoolbox/etoolbox.sty index d7dbd75ef39..6556156fe50 100644 --- a/Master/texmf-dist/tex/latex/etoolbox/etoolbox.sty +++ b/Master/texmf-dist/tex/latex/etoolbox/etoolbox.sty @@ -1,4 +1,4 @@ -% $Id: etoolbox.sty,v 2.0 2010/08/21 17:07:46 lehman stable $ +% $Id: etoolbox.sty,v 2.0a 2010/09/12 11:42:38 lehman stable $ % Copyright (c) 2007-2010 Philipp Lehman. % @@ -18,7 +18,7 @@ \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{etoolbox} -[\etb@rcsid $Id: etoolbox.sty,v 2.0 2010/08/21 17:07:46 lehman stable $ +[\etb@rcsid $Id: etoolbox.sty,v 2.0a 2010/09/12 11:42:38 lehman stable $ e-TeX tools for LaTeX] \begingroup @@ -1104,36 +1104,36 @@ {\etb@error{\string#1 undefined}\@eha} {\ifdefmacro#1 {\ifdefltxprotect#1 - {\letcs\etb@tempa{\expandafter\@gobble\string#1 }% + {\letcs\etb@resrvda{\expandafter\@gobble\string#1 }% \@tempswatrue} - {\let\etb@tempa#1% + {\let\etb@resrvda#1% \@tempswafalse}% - \ifdefparam\etb@tempa - {\etb@ifscanable\etb@tempa - {\etb@robustify\etb@tempa - \let#1\etb@tempa} + \ifdefparam\etb@resrvda + {\etb@ifscanable\etb@resrvda + {\etb@robustify\etb@resrvda + \let#1\etb@resrvda} {\etb@error{Failed to robustify \string#1} {The command is special and cannot be handled by \string\robustify.}% \@tempswafalse}} - {\protected\edef#1{\expandonce\etb@tempa}} + {\protected\edef#1{\expandonce\etb@resrvda}} \if@tempswa \ifcsdef{\string#1 } {} {\csundef{\expandafter\@gobble\string#1 }}% \fi - \undef\etb@tempa} + \undef\etb@resrvda} {\etb@error{\string#1 not a macro}\@eha}}} \def\etb@robustify#1{% \begingroup - \edef\etb@resrvda{% - \def\noexpand\etb@resrvda####1\detokenize{macro}:####2->####3&{% - \protected####1\def\string#1####2{####3}}% - \edef\noexpand\etb@resrvda{% - \noexpand\etb@resrvda\meaning#1&}}% - \etb@resrvda - \etb@scantoks\endgroup\etb@resrvda} + \edef\etb@resrvdb{% + \def\noexpand\etb@resrvdb####1\detokenize{macro}:####2->####3&{% + \protected####1\def\string#1\space####2{####3}}% + \edef\noexpand\etb@resrvdb{% + \noexpand\etb@resrvdb\meaning#1&}}% + \etb@resrvdb + \etb@patchcmd@scantoks\etb@resrvdb} % {<cstoken>}{<search>}{<true}{<false>} % *{<cstoken>}{<true}{<false>} @@ -1198,20 +1198,21 @@ \begingroup \edef\etb@resrvda{% \def\noexpand\etb@resrvda####1\detokenize{macro:}####2->####3&{% - #1\csdef{\expandafter\@gobble\string#2}####2{\noexpand\etb@resrvdb####3&}}% + #1\def\string\etb@resrvda\space####2{\noexpand\etb@resrvdb####3&}}% \def\noexpand\etb@resrvdb####1\detokenize{#3}####2&{% ####1\detokenize{#4}####2}% \edef\noexpand\etb@resrvda{% \noexpand\etb@resrvda\meaning#2&}}% \etb@resrvda - \etb@scantoks\endgroup\etb@resrvda + \etb@patchcmd@scantoks\etb@resrvda + \let#2\etb@resrvda + \undef\etb@resrvda \@firstoftwo} {\@secondoftwo}} -\def\etb@scantoks#1#2{% - \begingroup +\def\etb@patchcmd@scantoks#1{% \edef\etb@resrvda{\endgroup - \unexpanded{#1\makeatletter\scantokens}{#2}% + \unexpanded{\makeatletter\scantokens}{#1}% \catcode\number`\@=\the\catcode`\@\relax}% \etb@resrvda} @@ -1261,11 +1262,13 @@ \begingroup \edef\etb@resrvda{% \def\noexpand\etb@resrvda####1\detokenize{macro}:####2->####3&{% - ####1\csdef{\expandafter\@gobble\string#2}####2{#1{####3}{\detokenize{#3}}}}% + ####1\def\string\etb@resrvda\space####2{#1{####3}{\detokenize{#3}}}}% \edef\noexpand\etb@resrvda{% \noexpand\etb@resrvda\meaning#2&}}% \etb@resrvda - \etb@scantoks\endgroup\etb@resrvda} + \etb@patchcmd@scantoks\etb@resrvda + \let#2\etb@resrvda + \undef\etb@resrvda} \long\def\etb@append#1#2{#1#2} \long\def\etb@prepend#1#2{#2#1} |