summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/alephdir
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2021-01-30 01:42:07 +0000
committerKarl Berry <karl@freefriends.org>2021-01-30 01:42:07 +0000
commit0bf3e49d4d147727e1daf1007362a871972b214f (patch)
tree63a54dcf8830af3f1f4672589b1ebce917693e57 /Build/source/texk/web2c/alephdir
parent62203043f467d3a24b34f2df151b65e6ea35144b (diff)
tuneup2021 from DEK, with adaptations for TL
git-svn-id: svn://tug.org/texlive/trunk@57558 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/alephdir')
-rw-r--r--Build/source/texk/web2c/alephdir/alephextra.h2
-rw-r--r--Build/source/texk/web2c/alephdir/com16bit.ch72
-rw-r--r--Build/source/texk/web2c/alephdir/eobase.ch15
-rw-r--r--Build/source/texk/web2c/alephdir/eocprt.ch2
-rw-r--r--Build/source/texk/web2c/alephdir/eoext.ch4
-rw-r--r--Build/source/texk/web2c/alephdir/eover.ch6
-rw-r--r--Build/source/texk/web2c/alephdir/om16bit.ch11
-rw-r--r--Build/source/texk/web2c/alephdir/omfont.ch6
-rw-r--r--Build/source/texk/web2c/alephdir/omstr.ch14
9 files changed, 77 insertions, 55 deletions
diff --git a/Build/source/texk/web2c/alephdir/alephextra.h b/Build/source/texk/web2c/alephdir/alephextra.h
index 3a997f0a926..786ed44d0bf 100644
--- a/Build/source/texk/web2c/alephdir/alephextra.h
+++ b/Build/source/texk/web2c/alephdir/alephextra.h
@@ -23,7 +23,7 @@ along with Aleph; if not, write to the Free Software Foundation, Inc.,
*/
-#define BANNER "This is Aleph, Version 3.14159265-1.15-2.1-0.1"
+#define BANNER "This is Aleph, Version 3.141592653-1.15-2.1-0.1"
#define COPYRIGHT_HOLDER "Aleph task force"
#define AUTHOR NULL
#define PROGRAM_HELP ALEPHHELP
diff --git a/Build/source/texk/web2c/alephdir/com16bit.ch b/Build/source/texk/web2c/alephdir/com16bit.ch
index 3ac2ffce5ac..78a7047adb2 100644
--- a/Build/source/texk/web2c/alephdir/com16bit.ch
+++ b/Build/source/texk/web2c/alephdir/com16bit.ch
@@ -40,9 +40,9 @@
@z
@x
-@d banner=='This is Aleph, Version 3.14159265-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
+@d banner=='This is Aleph, Version 3.141592653-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
@y
-@d banner=='This is Aleph, Version 3.14159265-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
+@d banner=='This is Aleph, Version 3.141592653-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
@d banner_k==banner {Web2C announces itself}
@z
@@ -740,13 +740,14 @@ end;
% selector from 16 to 15 in term_input, due to the lack of this check in
% a recursive error() call.
%
-@x [6.83] l.1893 - avoid wrong interaction
-loop@+begin continue: clear_for_error_prompt; prompt_input("? ");
-@y
-loop@+begin continue:
-if interaction<>error_stop_mode then return;
-clear_for_error_prompt; prompt_input("? ");
-@z
+%@x [6.83] l.1893 - avoid wrong interaction
+%applied in 3.141592653
+%loop@+begin continue: clear_for_error_prompt; prompt_input("? ");
+%@y
+%loop@+begin continue:
+%if interaction<>error_stop_mode then return;
+%clear_for_error_prompt; prompt_input("? ");
+%@z
@x [6.84] l.1904 - Implement the switch-to-editor option.
line ready to be edited. But such an extension requires some system
@@ -774,14 +775,14 @@ been commented~out.
@z
@x [6.84] l.1903 - Implement the switch-to-editor option.
-"E": if base_ptr>0 then
+"E": if base_ptr>0 then if input_stack[base_ptr].name_field>=256 then
begin print_nl("You want to edit file ");
@.You want to edit file x@>
slow_print(input_stack[base_ptr].name_field);
print(" at line "); print_int(line);
interaction:=scroll_mode; jump_out;
@y
-"E": if base_ptr>0 then
+"E": if base_ptr>0 then if input_stack[base_ptr].name_field>=256 then
begin edit_name_start:=str_start(edit_file.name_field);
edit_name_length:=str_start(edit_file.name_field+1) -
str_start(edit_file.name_field);
@@ -950,23 +951,24 @@ page_depth:=0; page_max_depth:=0;
input and output, establishes the initial values of the date and time.
@^system dependencies@>
Since standard \PASCAL\ cannot provide such information, something special
-is needed. The program here simply specifies July 4, 1776, at noon; but
-users probably want a better approximation to the truth.
+is needed. The program here simply assumes that suitable values appear in
+the global variables \\{sys\_time}, \\{sys\_day}, \\{sys\_month}, and
+\\{sys\_year} (which are initialized to noon on 4 July 1776,
+in case the implementor is careless).
@p procedure fix_date_and_time;
-begin time:=12*60; {minutes since midnight}
-day:=4; {fourth day of the month}
-month:=7; {seventh month of the year}
-year:=1776; {Anno Domini}
+begin sys_time:=12*60;
+sys_day:=4; sys_month:=7; sys_year:=1776; {self-evident truths}
+time:=sys_time; {minutes since midnight}
+day:=sys_day; {day of the month}
+month:=sys_month; {month of the year}
+year:=sys_year; {Anno Domini}
end;
@y
@ The following procedure, which is called just before \TeX\ initializes its
input and output, establishes the initial values of the date and time.
-It calls a macro-defined |date_and_time| routine. |date_and_time|
-in turn is a C macro, which calls |get_date_and_time|, passing
-it the addresses of the day, month, etc., so they can be set by the
-routine. |get_date_and_time| also sets up interrupt catching if that
-is conditionally compiled in the C code.
+It calls an externally defined |date_and_time|, which also sets up
+interrupt catching. See more comments in \.{tex.ch}.
@^system dependencies@>
@d fix_date_and_time==o_date_and_time(int_base+time_code,
@@ -1624,7 +1626,7 @@ if name=str_ptr-1 then {we can try to conserve string pool space now}
@z
@x [29.537] l.10359 - start_input: don't return filename to string pool.
-if name=str_ptr-1 then {we can conserve string pool space now}
+if name=str_ptr-1 then {conserve string pool space (but see note above)}
begin flush_string; name:=cur_name;
end;
@y
@@ -2009,9 +2011,9 @@ not_found:
@z
@x [43.943] l.18346 - web2c can't parse negative lower bounds in arrays. Sorry.
-@!init@! trie_op_hash:array[-trie_op_size..trie_op_size] of 0..trie_op_size;
+@!init @!trie_op_hash:array[-trie_op_size..trie_op_size] of 0..trie_op_size;
@y
-@!init@! trie_op_hash:array[neg_trie_op_size..trie_op_size] of 0..trie_op_size;
+@!init @!trie_op_hash:array[neg_trie_op_size..trie_op_size] of 0..trie_op_size;
@z
@x [43.944] l.18365 - web2c can't parse negative lower bounds in arrays. Sorry
@@ -2057,7 +2059,7 @@ tini
@z
@x [43.590] l.18524 - Dynamically allocate & larger tries.
-@!init@!trie_taken:packed array[1..trie_size] of boolean;
+@!init @!trie_taken:packed array[1..trie_size] of boolean;
{does a family start here?}
@t\hskip10pt@>@!trie_min:array[ASCII_code] of trie_pointer;
{the first possible slot for each character}
@@ -2065,7 +2067,7 @@ tini
@t\hskip10pt@>@!trie_not_ready:boolean; {is the trie still in linked form?}
tini
@y
-@!init@!trie_taken: ^boolean;
+@!init @!trie_taken: ^boolean;
{does a family start here?}
@t\hskip10pt@>@!trie_min:^trie_pointer;
{the first possible slot for each character}
@@ -2616,6 +2618,12 @@ final_end: do_final_end;
end {|main_body|};
@z
+@x
+begin @<Finish the extensions@>; new_line_char:=-1;
+@y
+begin @<Finish the extensions@>; set_new_eqtb_int(int_base+new_line_char_code,-1);
+@z
+
@x [51.1333] l.24254 - Print new line before termination; switch to editor if necessary.
slow_print(log_name); print_char(".");
end;
@@ -2634,6 +2642,12 @@ if (edit_name_start<>0) and (interaction>batch_mode) then
@y
@z
+@x
+begin c:=cur_chr; if c<>1 then new_line_char:=-1;
+@y
+begin c:=cur_chr; if c<>1 then set_new_eqtb_int(int_base+new_line_char_code,-1);
+@z
+
@x [51.1335] l.24335 - Only do dump if ini.
begin @!init for c:=top_mark_code to split_bot_mark_code do
if cur_mark[c]<>null then delete_token_ref(cur_mark[c]);
@@ -2687,8 +2701,8 @@ if trie_not_ready then begin {initex without format loaded}
% running. The best approximation is to do a core dump, then run the
% debugger on it later.
@x [52.1338] l.24411 - Core-dump in debugging mode on 0 input.
- begin goto breakpoint;@\ {go to every label at least once}
- breakpoint: m:=0; @{'BREAKPOINT'@}@\
+ begin goto breakpoint;@/ {go to every declared label at least once}
+ breakpoint: m:=0; @{'BREAKPOINT'@}@/
end
@y
dump_core {do something to cause a core dump}
diff --git a/Build/source/texk/web2c/alephdir/eobase.ch b/Build/source/texk/web2c/alephdir/eobase.ch
index a0d7d0ab007..080b99c50fc 100644
--- a/Build/source/texk/web2c/alephdir/eobase.ch
+++ b/Build/source/texk/web2c/alephdir/eobase.ch
@@ -39,8 +39,9 @@
@x limbo l.1 - this is e-TeX
%
% This program is copyright (C) 1982 by D. E. Knuth; all rights are reserved.
-% Copying of this file is authorized only if (1) you are D. E. Knuth, or if
-% (2) you make absolutely no changes to your copy. (The WEB system provides
+% Unlimited copying and redistribution of this file are permitted as long
+% as this file is not modified. Modifications are permitted, but only if
+% the resulting file is not named tex.web. (The WEB system provides
% for alterations via an auxiliary file; the master file should stay intact.)
% See Appendix H of the WEB manual for hints on how to install this program.
% And see Appendix A of the TRIP manual for details about how to validate it.
@@ -182,11 +183,11 @@ to be known as `\Aleph'.
@z
%---------------------------------------
@x [1] m.2 l.187 - e-TeX basic
-@d banner=='This is Omega, Version 3.14159265--1.15' {printed when \TeX\ starts}
+@d banner=='This is Omega, Version 3.141592653--1.15' {printed when \TeX\ starts}
@y
-@d banner=='This is Aleph, Version 3.14159265--1.15--2.1' {printed when \TeX\ starts}
+@d banner=='This is Aleph, Version 3.141592653--1.15--2.1' {printed when \TeX\ starts}
@#
-@d eTeX_version_string=='3.14159265--1.15--2.1' {current \eTeX\ version}
+@d eTeX_version_string=='3.141592653--1.15--2.1' {current \eTeX\ version}
@d eTeX_version=2 { \.{\\eTeXversion} }
@d eTeX_revision==".1" { \.{\\eTeXrevision} }
@#
@@ -2361,9 +2362,9 @@ set_shape: begin q:=cur_chr; scan_optional_equals; scan_int; n:=cur_val;
@z
%---------------------------------------
@x [49] m.1292 l.23581 - e-TeX show_groups
- show_lists:print_esc("showlists");
+ show_lists_code:print_esc("showlists");
@y
- show_lists:print_esc("showlists");
+ show_lists_code:print_esc("showlists");
@<Cases of |xray| for |print_cmd_chr|@>@;@/
@z
%---------------------------------------
diff --git a/Build/source/texk/web2c/alephdir/eocprt.ch b/Build/source/texk/web2c/alephdir/eocprt.ch
index 738115289a9..0e2705a3a2d 100644
--- a/Build/source/texk/web2c/alephdir/eocprt.ch
+++ b/Build/source/texk/web2c/alephdir/eocprt.ch
@@ -7,6 +7,6 @@ wterm_ln('Copyright (c) 1994--2000 John Plaice and Yannis Haralambous');
print_nl("Copyright (c) 1994--2000 John Plaice and Yannis Haralambous");
@y
print_nl("Copyright (C) 1994--2000 John Plaice and Yannis Haralambous");
-print_nl("Copyright (C) 2002--2009 Aleph task force");
+print_nl("Copyright (C) 2002--2021 Aleph task force");
@z
diff --git a/Build/source/texk/web2c/alephdir/eoext.ch b/Build/source/texk/web2c/alephdir/eoext.ch
index 08432788270..4fd45003f22 100644
--- a/Build/source/texk/web2c/alephdir/eoext.ch
+++ b/Build/source/texk/web2c/alephdir/eoext.ch
@@ -62,9 +62,9 @@ print_err("Aleph capacity exceeded, sorry [");
@z
%----------------------------------------
@x
- print("Omega output, Version 3.14159265--1.15, ");
+ print("Omega output, Version 3.141592653--1.15, ");
@y
- print("Aleph output, Version 3.14159265--1.15--2.1, ");
+ print("Aleph output, Version 3.141592653--1.15--2.1, ");
@z
%----------------------------------------
@x
diff --git a/Build/source/texk/web2c/alephdir/eover.ch b/Build/source/texk/web2c/alephdir/eover.ch
index 0384368969d..1d9ed63a903 100644
--- a/Build/source/texk/web2c/alephdir/eover.ch
+++ b/Build/source/texk/web2c/alephdir/eover.ch
@@ -5,9 +5,9 @@
% * we add both \eTeX-like and \OMEGA-like
% commands to display the version
@x
-@d banner=='This is Aleph, Version 3.14159265--1.15--2.1' {printed when \TeX\ starts}
+@d banner=='This is Aleph, Version 3.141592653--1.15--2.1' {printed when \TeX\ starts}
@#
-@d eTeX_version_string=='3.14159265--1.15--2.1' {current \eTeX\ version}
+@d eTeX_version_string=='3.141592653--1.15--2.1' {current \eTeX\ version}
@d eTeX_version=2 { \.{\\eTeXversion} }
@d eTeX_revision==".1" { \.{\\eTeXrevision} }
@#
@@ -30,7 +30,7 @@
@d Omega_revision==".15" { \.{\\Omegarevision} }
@d Aleph_revision==".0" { \.{\\Alephrevision} }
@#
-@d banner=='This is Aleph, Version 3.14159265-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
+@d banner=='This is Aleph, Version 3.141592653-',Omega_version_banner,'-',eTeX_version_banner,'-',Aleph_version_banner {printed when \TeX\ starts}
@d eTeX_banner==banner
{printed when \eTeX\ starts}
@z
diff --git a/Build/source/texk/web2c/alephdir/om16bit.ch b/Build/source/texk/web2c/alephdir/om16bit.ch
index 41f711372e5..352c8903e20 100644
--- a/Build/source/texk/web2c/alephdir/om16bit.ch
+++ b/Build/source/texk/web2c/alephdir/om16bit.ch
@@ -74,9 +74,9 @@ author' in the documentation are to D. E. Knuth.
@z
%---------------------------------------
@x [1] m.2 l.187 - Omega
-@d banner=='This is TeX, Version 3.14159265' {printed when \TeX\ starts}
+@d banner=='This is TeX, Version 3.141592653' {printed when \TeX\ starts}
@y
-@d banner=='This is Omega, Version 3.14159265--1.15' {printed when \TeX\ starts}
+@d banner=='This is Omega, Version 3.141592653--1.15' {printed when \TeX\ starts}
@z
%---------------------------------------
@x [1] m.4 l.243
@@ -1558,6 +1558,7 @@ text(frozen_cr):="cr"; eqtb[frozen_cr]:=eqtb[cur_val];@/
primitive("crcr",car_ret,cr_cr_code);
@!@:cr_cr_}{\.{\\crcr} primitive@>
text(frozen_end_template):="endtemplate"; text(frozen_endv):="endtemplate";
+@.endtemplate@>
eq_type(frozen_endv):=endv; equiv(frozen_endv):=null_list;
eq_level(frozen_endv):=level_one;@/
eqtb[frozen_end_template]:=eqtb[frozen_endv];
@@ -1616,7 +1617,8 @@ be between 0 and |biggest_char|, otherwise hyphenation will not be attempted.
%---------------------------------------
@x [40] m.892 l.17469 - Omega
@!hc:array[0..65] of 0..256; {word to be hyphenated}
-@!hn:small_number; {the number of positions occupied in |hc|}
+@!hn:0..64; {the number of positions occupied in |hc|;
+ not always a |small_number|}
@!ha,@!hb:pointer; {nodes |ha..hb| should be replaced by the hyphenated result}
@!hf:internal_font_number; {font number of the letters in |hc|}
@!hu:array[0..63] of 0..256; {like |hc|, before conversion to lowercase}
@@ -1626,7 +1628,8 @@ be between 0 and |biggest_char|, otherwise hyphenation will not be attempted.
@!hyf_bchar:halfword; {boundary character after $c_n$}
@y
@!hc:array[0..65] of 0..too_big_char; {word to be hyphenated}
-@!hn:small_number; {the number of positions occupied in |hc|}
+@!hn:0..64; {the number of positions occupied in |hc|;
+ not always a |small_number|}
@!ha,@!hb:pointer; {nodes |ha..hb| should be replaced by the hyphenated result}
@!hf:internal_font_number; {font number of the letters in |hc|}
@!hu:array[0..63] of 0..too_big_char;
diff --git a/Build/source/texk/web2c/alephdir/omfont.ch b/Build/source/texk/web2c/alephdir/omfont.ch
index eb718688508..35453b353ce 100644
--- a/Build/source/texk/web2c/alephdir/omfont.ch
+++ b/Build/source/texk/web2c/alephdir/omfont.ch
@@ -279,7 +279,7 @@ These bytes are the character codes of individual pieces used to
{start of |lig_kern| program for left boundary character,
|non_address| if there is none}
@!font_bchar:array[internal_font_number] of min_quarterword..non_char;
- {right boundary character, |non_char| if there is none}
+ {boundary character, |non_char| if there is none}
@!font_false_bchar:array[internal_font_number] of min_quarterword..non_char;
{|font_bchar| if it doesn't exist in the font, otherwise |non_char|}
@y
@@ -619,9 +619,9 @@ that do not do local optimization.
@z
%---------------------------------------
@x [30] m.560 l.10888 - Omega
-@!bchar:0..256; {right boundary character, or 256}
+@!bchar:0..256; {boundary character, or 256}
@y
-@!bchar:0..too_big_char; {right boundary character, or |too_big_char|}
+@!bchar:0..too_big_char; {boundary character, or |too_big_char|}
@!first_two:integer;
@z
%---------------------------------------
diff --git a/Build/source/texk/web2c/alephdir/omstr.ch b/Build/source/texk/web2c/alephdir/omstr.ch
index 702e6f778c5..cbfd28fb2c4 100644
--- a/Build/source/texk/web2c/alephdir/omstr.ch
+++ b/Build/source/texk/web2c/alephdir/omstr.ch
@@ -758,17 +758,21 @@ else begin for k:=1 to name_length do append_char(name_of_file[k]);
@x [29] m.536 l.10324 - Omega
begin wlog(banner);
slow_print(format_ident); print(" ");
-print_int(day); print_char(" ");
+print_int(sys_day); print_char(" ");
months:='JANFEBMARAPRMAYJUNJULAUGSEPOCTNOVDEC';
-for k:=3*month-2 to 3*month do wlog(months[k]);
-print_char(" "); print_int(year); print_char(" ");
-print_two(time div 60); print_char(":"); print_two(time mod 60);
+for k:=3*sys_month-2 to 3*sys_month do wlog(months[k]);
+print_char(" "); print_int(sys_year); print_char(" ");
+print_two(sys_time div 60); print_char(":"); print_two(sys_time mod 60);
end
@y
begin wlog(banner);
slow_print(format_ident); print_nl("");
print_int(day); print_char(" ");
months:='JANFEBMARAPRMAYJUNJULAUGSEPOCTNOVDEC';
+{don't output garbage if nefarious user sets invalid month value;
+ this error message never actually shows up, the program just aborts,
+ but it doesn't matter in practice.}
+if (month < 1) or (month > 12) then fatal_error("month out of range 1..12");
for k:=3*month-2 to 3*month do wlog(months[k]);
print_char(" "); print_int(year); print_char(" ");
print_two(time div 60); print_char(":"); print_two(time mod 60);
@@ -785,7 +789,7 @@ end
@x [32] m.617 l.12262 - Omega
print(" TeX output "); print_int(year); print_char(".");
@y
- print("Omega output, Version 3.14159265--1.15, ");
+ print("Omega output, Version 3.141592653--1.15, ");
print_int(year); print_char(".");
@z
%---------------------------------------