summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/etexdir
diff options
context:
space:
mode:
authorPeter Breitenlohner <peb@mppmu.mpg.de>2011-03-26 15:29:43 +0000
committerPeter Breitenlohner <peb@mppmu.mpg.de>2011-03-26 15:29:43 +0000
commit83c77a6f9ab33bc5aab2fd8bda79e11524cca702 (patch)
treebde2639dcd021a947b9318eb0dfd7538a4bb0448 /Build/source/texk/web2c/etexdir
parent8bea2fb9f960bdb62f8be6bbb2c9b740b437702d (diff)
e-pTeX: reformulate/simplify \lastbox, \unpenalty & Co
git-svn-id: svn://tug.org/texlive/trunk@21837 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/etexdir')
-rw-r--r--Build/source/texk/web2c/etexdir/etex.ch16
1 files changed, 9 insertions, 7 deletions
diff --git a/Build/source/texk/web2c/etexdir/etex.ch b/Build/source/texk/web2c/etexdir/etex.ch
index f82dc094e35..a3d4ba5cbd1 100644
--- a/Build/source/texk/web2c/etexdir/etex.ch
+++ b/Build/source/texk/web2c/etexdir/etex.ch
@@ -1182,7 +1182,7 @@ else if par_shape_ptr=null then cur_val:=0
@x [26] m.424 l.8510 - e-TeX TeXXeT
@<Fetch an item in the current node...@>=
@y
-@d find_effective_tail_eTeX(#)== {Ignore final \.{\\endM} node}
+@d find_effective_tail_eTeX(#)== {sets |tx| to last non-\.{\\endM} node}
if (type(tail)=math_node)and(subtype(tail)=end_M_code) then
begin tx:=head;
while link(tx)<>tail do tx:=link(tx);
@@ -2325,7 +2325,8 @@ copy_code: begin scan_register_num; fetch_box(q); cur_box:=copy_node_list(q);
@x [47] m.1080 l.20940 - e-TeX TeXXeT
@<If the current list ends with a box node, delete it...@>=
@y
-@d fetch_effective_tail_eTeX(#)==
+@d fetch_effective_tail_eTeX(#)== {extract |tx|,
+ drop \.{\\beginM} \.{\\endM} pair}
q:=head; p:=null;
repeat r:=p; p:=q; fm:=false;
if not is_char_node(q) then
@@ -2335,12 +2336,13 @@ if not is_char_node(q) then
end
else if (type(q)=math_node)and(subtype(q)=begin_M_code) then fm:=true;
q:=link(p);
-until q=tx;
+until q=tx; {found |r|$\to$|p|$\to$|q=tx|}
q:=link(tx); link(p):=q; link(tx):=null;
-if q=null then tail:=p
-else if fm then
- begin tail:=r; link(r):=null; flush_node_list(p);
- end
+if q=null then if fm then confusion("tail1")
+@:this can't happen tail1}{\quad tail1@>
+ else tail:=p
+else if fm then {|r|$\to$|p=begin_M|$\to$|q=end_M|}
+ begin tail:=r; link(r):=null; flush_node_list(p);@+end
@#
@d fetch_effective_tail==fetch_effective_tail_eTeX