summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/xint/xintbinhex.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/xint/xintbinhex.sty')
-rw-r--r--Master/texmf-dist/tex/generic/xint/xintbinhex.sty55
1 files changed, 16 insertions, 39 deletions
diff --git a/Master/texmf-dist/tex/generic/xint/xintbinhex.sty b/Master/texmf-dist/tex/generic/xint/xintbinhex.sty
index 4a3be168fc7..4888a8124cb 100644
--- a/Master/texmf-dist/tex/generic/xint/xintbinhex.sty
+++ b/Master/texmf-dist/tex/generic/xint/xintbinhex.sty
@@ -21,7 +21,7 @@
%% same distribution. (The sources need not necessarily be
%% in the same archive or directory.)
%% ---------------------------------------------------------------
-%% The xint bundle 1.2n 2017/08/06
+%% The xint bundle 1.2o 2017/08/29
%% Copyright (C) 2013-2017 by Jean-Francois Burnol
%% xintbinhex: Expandable binary and hexadecimal conversions
%% ---------------------------------------------------------------
@@ -70,7 +70,7 @@
\XINTsetupcatcodes% defined in xintkernel.sty
\XINT_providespackage
\ProvidesPackage{xintbinhex}%
- [2017/08/06 1.2n Expandable binary and hexadecimal conversions (JFB)]%
+ [2017/08/29 1.2o Expandable binary and hexadecimal conversions (JFB)]%
\newcount\xint_c_ii^xv \xint_c_ii^xv 32768
\newcount\xint_c_ii^xvi \xint_c_ii^xvi 65536
\def\XINT_tmpa #1{\ifx\relax#1\else
@@ -128,20 +128,6 @@
\def\XINT_zeroes_foriv_end\R\XINT_zeroes_foriv #1#2\W
{\XINT_zeroes_foriv_done #1}%
\def\XINT_zeroes_foriv_done #1\R{ #1}%
-\def\XINT_unsepb_loop #1!#2!#3!#4!#5!#6!#7!#8!#9!%
-{%
- \expandafter\XINT_unsep_clean
- \the\numexpr 1#1\expandafter\XINT_unsep_clean
- \the\numexpr 1#2\expandafter\XINT_unsep_clean
- \the\numexpr 1#3\expandafter\XINT_unsep_clean
- \the\numexpr 1#4\expandafter\XINT_unsep_clean
- \the\numexpr 1#5\expandafter\XINT_unsep_clean
- \the\numexpr 1#6\expandafter\XINT_unsep_clean
- \the\numexpr 1#7\expandafter\XINT_unsep_clean
- \the\numexpr 1#8\expandafter\XINT_unsep_clean
- \the\numexpr 1#9\XINT_unsepb_loop
-}%
-\def\XINT_unsep_clean 1{\relax}% also in xintcore
\def\xintDecToHex {\romannumeral0\xintdectohex }%
\def\xintdectohex #1%
{%
@@ -173,9 +159,10 @@
\expandafter\XINT_dthb_again\the\numexpr\expandafter\XINT_dthb_update
\the\numexpr#1#2#3#4%
\xint_bye#9\XINT_dthb_lastpass\xint_bye
- #5#6#7#8!\XINT_dthb_exclam\relax\XINT_dthb_nextfour!2!3!4!5!6!7!8!9!\Z #9%
+ #5#6#7#8!\XINT_dthb_exclam\relax\XINT_dthb_nextfour #9%
}%
-\def\XINT_dthb_exclam {!\XINT_dthb_exclam!}%
+\def\XINT_dthb_exclam {!\XINT_dthb_exclam\relax
+ \expandafter\XINT_dthb_update\the\numexpr}%
\def\XINT_dthb_update #1!%
{%
\expandafter\XINT_dthb_update_a
@@ -186,10 +173,10 @@
{%
0000+#1\expandafter#3\the\numexpr#2-#1*\xint_c_ii^xvi
}%
-\def\XINT_dthb_nextfour #1\Z #2#3#4#5#6%
+\def\XINT_dthb_nextfour #1#2#3#4#5%
{%
- \xint_bye#6\XINT_dthb_lastpass\xint_bye
- #2#3#4#5!\XINT_dthb_exclam\relax\XINT_dthb_nextfour!2!3!4!5!6!7!8!9!\Z #6%
+ \xint_bye#5\XINT_dthb_lastpass\xint_bye
+ #1#2#3#4!\XINT_dthb_exclam\relax\XINT_dthb_nextfour#5%
}%
\def\XINT_dthb_lastpass\xint_bye #1!#2\xint_bye#3{#1!#3!}%
\def\XINT_dth_tohex
@@ -197,28 +184,18 @@
\expandafter\expandafter\expandafter\XINT_dth_tohex_a\csname\XINT_tofourhex
}%
\def\XINT_dth_tohex_a\endcsname{!\XINT_dth_tohex!}%
-\def\XINT_dthb_a #1!#2!#3!#4!#5!#6!#7!#8!#9!%
-{%
- \expandafter\XINT_dthb_update
- \the\numexpr #1\expandafter\XINT_dthb_update
- \the\numexpr #2\expandafter\XINT_dthb_update
- \the\numexpr #3\expandafter\XINT_dthb_update
- \the\numexpr #4\expandafter\XINT_dthb_update
- \the\numexpr #5\expandafter\XINT_dthb_update
- \the\numexpr #6\expandafter\XINT_dthb_update
- \the\numexpr #7\expandafter\XINT_dthb_update
- \the\numexpr #8\expandafter\XINT_dthb_update
- \the\numexpr #9\XINT_dthb_a
-}%
-\def\XINT_dthb_again #1!#2!%
-{%
- \ifx\XINT_dthb_exclam#2%
+\def\XINT_dthb_again #1!#2#3%
+{%
+ \ifx#3\relax
\expandafter\xint_firstoftwo
\else
\expandafter\xint_secondoftwo
\fi
- {\expandafter\XINT_dthb_again\the\numexpr\expandafter\XINT_dthb_a
- \romannumeral`&&@\ifnum #1>\xint_c_ \xint_dothis{#1!}\fi\xint_orthat{}}%
+ {\expandafter\XINT_dthb_again
+ \the\numexpr
+ \ifnum #1>\xint_c_
+ \xint_afterfi{\expandafter\XINT_dthb_update\the\numexpr#1}%
+ \fi}%
{\ifnum #1>\xint_c_ \xint_dothis{#2#1!}\fi\xint_orthat{!#2!}}%
}%
\def\XINT_tofourhex #1!%