diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/silence/silence-doc.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/silence/silence-doc.dtx | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/Master/texmf-dist/source/latex/silence/silence-doc.dtx b/Master/texmf-dist/source/latex/silence/silence-doc.dtx index 3004c024ab9..2be90905a9f 100644 --- a/Master/texmf-dist/source/latex/silence/silence-doc.dtx +++ b/Master/texmf-dist/source/latex/silence/silence-doc.dtx @@ -73,6 +73,7 @@ %\Change{v1.2}{2009/04/02}{\texttt{LaTeX Font Warning}s can be filtered} %\Change{v1.3}{2010/02/28}{Compatibility with Lua\TeX} %\Change{v1.4}{2011/12/06}{Fixed the \texttt{\string\@gobbletwo} error} +%\Change{v1.4}{2012/01/26}{Fixed the \texttt{\string\@gobble} error (same as before, spotted with biblatex)} % %\section{Introduction} %When working with \LaTeX, messages are utterly important. @@ -1349,13 +1350,24 @@ % (remember that no control sequence is formed in the % text of a starless filter, only strings of characters). % This expanded version is first stripped of a "\@gobbletwo" -% prefix, if any, thus avoiding error when "\edef"ing. +% suffix, if any, thus avoiding error when "\edef"ing. % (The "\@gobbletwo" occurs in some \LaTeX\ messages for -% some obscure reason.) +% some obscure reason.) ... And at least in biblatex "\@gobble" +% was also found, which also ruined everything, so it is removed +% too if found at the end of a message. % We do this in a group because, well, you know, % you shouldn't do that... % % \begin{macrocode} +\def\sl@RemoveGobble#1\@gobble\sl@Terminator#2\sl@Terminator{% + \def\sl@Tempb{#2}% + \ifx\sl@Tempb\@empty + \else + \def\sl@Tempa{#1}% + \expandafter\@gobble + \fi + } + \def\sl@RemoveGobbletwo#1\@gobbletwo\sl@Terminator#2\sl@Terminator{% \def\sl@Tempb{#2}% \ifx\sl@Tempb\@empty @@ -1374,6 +1386,7 @@ \let\protect\string \let\noexpand\string \def\sl@Tempa{#1}% + \sl@RemoveGobble#1\sl@Terminator\@gobble\sl@Terminator\sl@Terminator \sl@RemoveGobbletwo#1\sl@Terminator\@gobbletwo\sl@Terminator\sl@Terminator \edef\sl@Tempa{\sl@Tempa}% \global\expandafter\sl@Message\expandafter{\sl@Tempa}% |