summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Build/source/texk/web2c/ChangeLog6
-rw-r--r--Build/source/texk/web2c/cwebdir/ctwill-w2c.ch3
-rwxr-xr-xBuild/source/texk/web2c/tests/fix-changefile-lines.py24
-rw-r--r--Build/source/texk/web2c/tex.ch2
4 files changed, 14 insertions, 21 deletions
diff --git a/Build/source/texk/web2c/ChangeLog b/Build/source/texk/web2c/ChangeLog
index 2f26d8f0c01..a6cb59db599 100644
--- a/Build/source/texk/web2c/ChangeLog
+++ b/Build/source/texk/web2c/ChangeLog
@@ -1,3 +1,9 @@
+2024-06-28 Andreas Scherer <https://ascherer.github.io>
+
+ * cwebdir/ctwill-w2c.ch,
+ * tests/fix-changefile-lines.py,
+ * tex.ch: Simpler check for 'change section'.
+
2024-06-24 Andreas Scherer <https://ascherer.github.io>
* tests/fix-changefile-lines.py,
diff --git a/Build/source/texk/web2c/cwebdir/ctwill-w2c.ch b/Build/source/texk/web2c/cwebdir/ctwill-w2c.ch
index de038897845..cd7862e9be2 100644
--- a/Build/source/texk/web2c/cwebdir/ctwill-w2c.ch
+++ b/Build/source/texk/web2c/cwebdir/ctwill-w2c.ch
@@ -1072,11 +1072,10 @@ flush_buffer(out_ptr,false,false);
default: err_print(_("! Improper macro definition")); break;
@z
-@x [12.236] l.4370
+@x [12.237] l.4370
@ @<Start a format...@>= {
doing_format=true;
@y
-
@ @<Start a format...@>= {
doing_format=true;
is_macro=false;
diff --git a/Build/source/texk/web2c/tests/fix-changefile-lines.py b/Build/source/texk/web2c/tests/fix-changefile-lines.py
index 888ea6fdb13..2866101488c 100755
--- a/Build/source/texk/web2c/tests/fix-changefile-lines.py
+++ b/Build/source/texk/web2c/tests/fix-changefile-lines.py
@@ -151,6 +151,12 @@ class ChangeReader:
eprint(self._match_lines[0])
sys.exit(1)
if tex_line == self._match_lines[0]:
+ if tex_line.startswith("@*"):
+ part += 1
+ section +=1
+ elif tex_line.startswith("@ ") or tex_line == "@":
+ section += 1
+
for i in range(1, len(self._match_lines)):
try:
_, tex_line = web_reader.next_line()
@@ -168,24 +174,6 @@ class ChangeReader:
while self.advance_to_next_chunk():
part, section, line_number = self.find_match_in_web(web_reader)
- # Attempt to catch the case where something is inserted just before
- # the start of a section.
- match_start = self._match_lines[0].strip()[:2]
- for repl_index in range(self._pos + 1, len(self._lines)):
- repl_start = self._lines[repl_index].strip()[:2]
- # CWEB @qcomments@> are ignored; see ctwill-w2c.ch
- if repl_start != "@q":
- break
- if match_start == "@ " or match_start == "@":
- if repl_start in ["@ ", "@*", "@"]:
- section += 1
- elif match_start == "@*":
- if repl_start == "@*":
- part += 1
- section += 1
- elif repl_start in ["@ ", "@"]:
- section += 1
-
# Replace '@x' line with updated information.
new_line = self._lines[self._chunk_start]
diff --git a/Build/source/texk/web2c/tex.ch b/Build/source/texk/web2c/tex.ch
index 1ecc140099f..beca2f6efe5 100644
--- a/Build/source/texk/web2c/tex.ch
+++ b/Build/source/texk/web2c/tex.ch
@@ -5029,7 +5029,7 @@ if x=1 then mltex_enabled_p:=true
else if x<>0 then goto bad_fmt;
@z
-@x [54.1379] l.24996 - extra routines
+@x [55.1380] l.24996 - extra routines
@* \[55] Index.
@y