summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/mult-aux.mkxl
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/mult-aux.mkxl')
-rw-r--r--tex/context/base/mkiv/mult-aux.mkxl23
1 files changed, 16 insertions, 7 deletions
diff --git a/tex/context/base/mkiv/mult-aux.mkxl b/tex/context/base/mkiv/mult-aux.mkxl
index 8343fb8dd..ebe3d0f2a 100644
--- a/tex/context/base/mkiv/mult-aux.mkxl
+++ b/tex/context/base/mkiv/mult-aux.mkxl
@@ -194,8 +194,8 @@
\def\mult_interfaces_detokenize{\expandafter\expandafter\expandafter\detokenize\expandafter\expandafter\expandafter}
-\unexpanded\def\mult_interfaces_install_parameter_handler#1#2#3#4#5#6#7#8% inlining \csname*\endcsname is more efficient (#3 and #6 only)
- {\ifx#2\relax\let#2\empty\fi % it is hardly faster but produces less expansion tracing
+\unexpanded\def\mult_interfaces_install_parameter_handler#1#2#3#4#5#6#7#8#9% inlining \csname*\endcsname is more efficient (#3 and #6 only)
+ {\ifx#2\relax\let#2\empty\fi % it is hardly faster but produces less expansion tracing
\def#3##1{\csname\ifcsname#1#2:##1\endcsname#1#2:##1\else\expandafter#5\csname#1#2:\s!parent\endcsname{##1}\fi\endcsname}%
\def#4##1##2{\ifcsname##1:##2\endcsname##1:##2\else\expandafter#5\csname##1:\s!parent\endcsname{##2}\fi}%
%\def#5##1##2{\ifx##1\relax\??empty\else#4{##1}{##2}\fi}% is {} needed around ##1 ?
@@ -203,7 +203,8 @@
\def#5##1##2{\ifx##1\relax^^^^0019\else#4##1{##2}\fi}% is {} needed around ##1 ?
\def#6##1##2{\csname\ifcsname#1##1:##2\endcsname#1##1:##2\else\expandafter#5\csname#1##1:\s!parent\endcsname{##2}\fi\endcsname}%
\def#7##1{\detokenize\expandafter\expandafter\expandafter{\csname#1#2:##1\endcsname}}% always root, no backtrack
- \def#8##1{\begincsname#1#2:##1\endcsname}}
+ \def#8##1{\begincsname#1#2:##1\endcsname}
+ \def#9##1##2{\expandafter\let\expandafter##1\csname\ifcsname#1#2:##2\endcsname#1#2:##2\else\expandafter#5\csname#1#2:\s!parent\endcsname{##2}\fi\endcsname}}
\unexpanded\def\installparameterhandler#1#2%
{\normalexpanded
@@ -215,7 +216,8 @@
\expandafter\noexpand\csname do#2parentparameter\endcsname % or : #2_parent_parameter
\expandafter\noexpand\csname named#2parameter\endcsname
\expandafter\noexpand\csname detokenized#2parameter\endcsname
- \expandafter\noexpand\csname direct#2parameter\endcsname}} % strict#2parameter is gone
+ \expandafter\noexpand\csname direct#2parameter\endcsname
+ \expandafter\noexpand\csname letfrom#2parameter\endcsname}} % strict#2parameter is gone
\unexpanded\def\mult_interfaces_install_root_parameter_handler#1#2#3%
{\def#2##1{\detokenize\expandafter\expandafter\expandafter{\csname#1:##1\endcsname}}% always root
@@ -236,7 +238,8 @@
\def#5##1##2{\ifx##1\relax\else#4##1{##2}\fi}%
\def#6{#1#2:}%
\def#7##1{#1##1:}%
- \def#8{\ifx#2\empty\else\ifcsname#1#2:\s!parent\endcsname\else\expandafter\let\csname#1#2:\s!parent\endcsname#1\fi\fi}%
+% \def#8{\ifx#2\empty\else\ifcsname#1#2:\s!parent\endcsname\else\expandafter\let\csname#1#2:\s!parent\endcsname#1\fi\fi}%
+ \def#8{\ifx#2\empty\orelse\ifcsname#1#2:\s!parent\endcsname\else\expandafter\let\csname#1#2:\s!parent\endcsname#1\fi}%
\unexpanded\def#9##1{\expandafter\edef\csname#1##1:\s!parent\endcsname{#1#2}}}
\unexpanded\def\installparameterhashhandler#1#2%
@@ -314,11 +317,17 @@
\let\definehandlerparent\empty
+% \def\mult_check_for_parent#1#2#3#4%
+% {\ifcsname#1#4:\s!parent\endcsname \else \ifx#4\empty \else
+% \writestatus\m!system{error: invalid parent #4 for #3, #4 defined too (best check it)}%
+% \expandafter\edef\csname#1#4:\s!parent\endcsname{#2}%
+% \fi \fi}
+
\def\mult_check_for_parent#1#2#3#4%
- {\ifcsname#1#4:\s!parent\endcsname \else \ifx#4\empty \else
+ {\ifcsname#1#4:\s!parent\endcsname\orelse\ifx#4\empty\else
\writestatus\m!system{error: invalid parent #4 for #3, #4 defined too (best check it)}%
\expandafter\edef\csname#1#4:\s!parent\endcsname{#2}%
- \fi \fi}
+ \fi}
%def\mult_interfaces_chain#1#2{\ifcsname#1#2:\s!chain\endcsname\csname#1#2:\s!chain\endcsname\space\fi}
%def\getparentchain #1#2{\ifcsname#1#2:\s!chain\endcsname\csname#1#2:\s!chain\endcsname\fi}