Last Updated 18 November 2024.
	
Errors Contributed by Hanson Char in 2024
	
	p. 168: The \scan macro works only when it is invoked inside \obeyspaces. The following version is correct.
	
	\def\scan#1\end{\scanA#1\relax\relax}
      \def\scanA#1#2\relax{%
     \ifx#1\relax\relax
        \def\aux{#2}\if\aux\empty\else \scanA#2\relax\relax \fi
      \else \onestep#1\scanA#2\relax\relax \fi
    }
	
	p. 167, the bottom seven lines: Both versions of macro \reverse would fail compilation if the given parameter is empty, as in, for example, \reverse\end

To fix this, we could change the first version to something like:

    \def\reverse#1\end{{\reverseA#1\relax\end}}
    \def\reverseA#1#2\end{\ifx#1\relax \else
      \reverseA#2\relax\end\fi #1}

and the second version to something like,

        \def\reverse#1\end{{\reverseA#1\empty\end}}
        \def\reverseA#1#2\end{\def\aux{#2}%
          \ifx\empty\aux \else \reverseA#2\end \fi #1}
	
	p. 163:  The last line "\ifvmode\nointerlineskip\fi" in the definition of \grida is unnecessary.
	
	p. 460: The same correction applies to \gridb on p.460.
	
	p. 164: The definition of macro \gridC can be enhanced in two ways as follows:
	
	1. The recursion of \finishgrid can be made tail recursive via \expandafter\finishgrid.
	2. The macro currently cannot handle grids of a single column, but that’s easy enough to fix by adding a \vrule of zero width before the first column.

Here is a revised version that incorporates these considerations:

\newcount\ct
\def\gridC#1x#2(#3) {\ct=#2
  \begingroup
    \let\ag=\aftergroup
    \ag\edef\ag\tabline\ag{%
      \loop \ifnum\ct>1 \ag&\advance\ct-1 \repeat
      \ag\cr\ag}\endgroup
  \ct=#1
  \setbox0=\vbox{
    \halign{##\vrule height#3pt width0pt\tabskip=#3pt&&\vrule##\cr
      \finishgrid}}
    \boxit{\box0}0
}
\def\finishgrid{\tabline \ifnum\ct>1 \noalign{\hrule}
    \global\advance\ct-1 \expandafter\finishgrid\fi}
	
	p. 162, l. 16: The 4-line definitions of macros \slantA and \slantB can be improved by changing them to:
	
	\def\slantA{\hbox\bgroup \let\next=\slantAaux \next}
    \def\slantAaux{\raise\step\hbox{\Dot}\advance\step by\dotsize
      \advance\loup by1
      \ifnum\loup<6 \else \egroup \let\next=\relax\fi \next}
					
	\def\slantB#1{\hbox\bgroup
  	 \count1=#1\let\next=\slantBaux \next}
	\def\slantBaux{\raise\step\hbox{\Dot}\advance\step by\dotsize
  	 \advance\loup by1
  	 \ifnum\loup<\count1 \else \egroup \let\next=\relax\fi \next}

			The improvements are:
					
1. There is no need to reset \step to 0pt and \loup to 0, because any changes to them inside \slantA are scoped within \bgroup … \egroup.
2. The recursion in \slantA can be optimized to a tail-recursive form, avoiding the runtime overhead of an additional stack frame per call.
	
	p. 162, l. -10: The test "\slantB6It $math \slantB8 mode$" should be done in horizontal mode, otherwise it prints two lines.
	It should therefore be preceded with a \leavevmode or anything that implicitly triggers TeX to switch to horizontal mode.

	p. 162, l.-3: The text should be "because it does not have any features..."
	
	p. 160, l. 3. The entire 5-line paragraph that starts with "The discussion above shows ..." should be repleced with:
	
	"When TeX tries to skip over the then or the else part of the \ifnum,
it encounters the \iffalse and considers it as a nested conditional,
and then the \iftrue\fi as another level of nested conditional (with an empty body)
within the \iffalse, thus requiring the user to provide two \fi's for balancing.
If only one \fi is provided, it would match only with the inner conditional
thus creating an error."
	
	p. 140, l. -5: "This is done by \let\ ={\ } or, rather [351], \global\let\ =\space \def\space{\ }.”
	
	should be
	
	"This is done by \let\ ={\ } or, rather [352], {\obeyspaces\global\let\ =\space}, and [351] \def\space={ }.”
	
	p. 140, l. -16: The two lines

\setbox0=\hbox{,} \catcode`,=\active
\def,{,\kern-\wd0\kern\wd0}

cause an infinite loop and should be replaced with

\setbox0=\hbox{,} \catcode`,=\active
\def,{\copy0\kern-\wd0\kern\wd0}
	
	p. 457, answer to Ex. 5.26: The replacement text of

        \edef\abc{\romannumera18 \meaning A\string\abc \TeX}

should be

        `viiithe letter A\abcT\kern -.1667em\lower .5ex\hbox {E}\kern -.125emX’

Instead of

        `viiithe letter A\abc\relax’
	
	p. 132, Ex. 5.25: the expansion `separag{abc} should have single quotes on both sides (minor).
	
	p. 131, l. 20. "whose size is normally 200" Currently, in 2024, the size is 10000.
	
	P. 457, answer to Ex. 5.23 should be  "expansions of \outer macros. Notice that even the \end command is allowed inside a macro."

	p. 456, answer to Ex. 5.19 is wrong. It should be:
	
\let\then=\iffalse
\long\def\ifundefined#1\then{{%
  \edef\x{\meaning#1}%
  \let\e=\escapechar \escapechar=-1
  \edef\y{\string\undefined}\escapechar=\e
  \def\true{\iftrue}\def\false{\iffalse}%
  \def\next{\expandafter\expandafter\expandafter\aftergroup\ifx\x\y\true\else\false\fi}\next}}
	
	This clever macro is the brainchild of Hanson Char, October 27, 2024.
	
	p. 122, l. 11:	\setboxl=\vbox{\hsize 2in \noindent A small \vbox with text.
It will be moved left (even into the margin) or right to
demonstrate \expandafter.}

should be changed into:

\setboxl=\vbox{\hsize 2in \noindent A small {\tt \string\vbox} with text.
It will be moved left (even into the margin) or right to
demonstrate {\tt \string\expandafter}.}
	
	Also, \newcount\ctst should be declared. It was declared much earlier, on page 113, line 2 of section 5.4,

	p. 113, l. 3: "apace" should be "space"
	
	p.452, Answer to Exercise 3.50: The solution does not work when the macro parameters have values other than those provided in the book. Here is my similar macro \mystagbox which uses an approach different from yours:
	
 \def\mystagbox#1#2{\dimen0=#1 \advance\dimen0 by-#2
  \vbox to#1{\offinterlineskip
    % right line
    \vskip#1 \vskip-\thick \vskip-\dimen0 \vskip-#2
    \hbox to 0pt{\hskip#1 \hskip-\thick
    \vrule height#2 width\thick
    \hss}\vskip\dimen0 \vskip\thick \vskip-#1% at the top left
    % top line
    \hbox to 0pt{\hskip#1 \hskip-\thick \hskip-\dimen0 \hskip-#2
    \vrule width#2 height\thick
    \hss}% one \thick below the top left
    % left line
    \vskip\dimen0
    \hbox to 0pt{\vrule height#2 width\thick\hss
    }\vskip-#2 \vskip-\dimen0 \vskip-\thick \vskip#1% at the bottom left
    % % bottom line
    \vskip-\thick
    \hbox to 0pt{\hskip\thick \hskip\dimen0
    \vrule height\thick width#2
    \hss}\vss}}
	
	p. 78, Exercise 3.49: "The size of the arrows is $10+4+2\times 4=22$pt, except the parskip arrow, whose size is $2\times 4=8$pt"
	should be
	"The size of the arrows is $10+4+2\times 4=22$pt, except the parskip arrow, whose size is $2\times 2\times 4=16$pt"
	
	Also, the \varfill macro should be
	
  \def\varrowfill#1{%
  \vbox to#1{\offinterlineskip
    \setbox0=\hbox{$\uparrow$}%
    \setbox1=\vbox{\hbox to\wd0{\hss$\vert$\hss}\null}%
    \box0
    \vskip-\ht1
    \cleaders\copy1\vfil
    \vskip-\ht1
    \vbox{\hbox{$\downarrow$}\null}}}
	
	p. 73, l. -2:
	The asterisk at the end of \setbox10=\hbox{$*$}* should be deleted.
	
	p. 447, answer to exercise 3.43: The first version of macro \depthit#1 has a slight mistake and should be:

\def\depthit#1{\setbox0=\hbox{#1}%
\vbox{\kern-0.4pt\hrule
\kern\ht0\kern\dp0\hrule\kern-0.4pt\kern-\ht0\kern-\dp0
\hbox{\vrule\box0\vrule}}}
	
	p. 78, Exercise 3.46:  The exercise asks to typeset a \vbox of 3 inches wide. This should be 3.5 inches. Also, in the comments box, the last age group should be 31--
	
	p. 78, Exercise 3.47: "using boxes, glue, and the \boxit macro" The words "\boxit macro" should be deleted. The answer (on page 450) doesn't use \boxit. 
	
	Also, in the answer, the \vbox for the right part has a missing \offinterlineskip, causing the output to be typeset incorrectly.  In particular, the down arrow below the text "depth" would be mispositioned.
	The correct code is:
	
	% the right part
 \vbox{\offinterlineskip
  \vtop to48pt{\boxmaxdepth=0pt % the depth of the downarrow should
    % become part of the total height of 48pt.
    \hbox{$\uparrow$}\vfil\hbox{\sevenrm height}\vfil%
    \hbox{$\downarrow$}}
    \vbox to30pt{% the \null below guarantees zero depth
      \hbox{$\uparrow$}\vss\hbox{\sevenrm depth}\vss%
      \hbox{$\downarrow$}\null}
 }
	

========================================================================
	
	
Errors Contributed by Nelson H. F. Beebe

This file records errata in the book

@String{pub-SV                  = "Spring{\-}er-Ver{\-}lag"}
@String{pub-SV:adr              = "Berlin, Germany~/ Heidelberg,
                                  Germany~/ London, UK~/ etc."}

@Book{Salomon:1995:AT,
  author =       "David Salomon",
  title =        "The Advanced {\TeX}book",
  publisher =    pub-SV,
  address =      pub-SV:adr,
  year =         "1995",
  ISBN =         "0-387-94556-3",
  LCCN =         "Z253.4.T47 S25 1995",
  acknowledgement = ack-nhfb,
  pages =        "xx + 490",
  price =        "US\$39.95",
  bibdate =      "Wed Nov 08 16:46:55 1995",
}

In the following, negative line numbers count from the bottom of the
page.


p. vii, l. -1:
        TeXand ->
        TeX and

p. 22, l. -17:
        13_5: the text should note here that the subscript 5 refers
        to the catcode

p. 23, l. 15:
        mutiplies ->
        multiplies

p. 55, l. -9:
        The text "which produces" just before the figure should not
        be indented.

p. 68, l. -16:
        Sanskrit), which are often ->
        Sanskrit); they are often

p. 89, l. 21:
        The line "To break ... \break," is very loose, and is not
        right justified.

p. 91, l. -9 there is a space
         missing at the end of the argument in the quoted macro: according
         to the discussion on p. 95, it should read

          \hbox{.*\setbox0=\hbox{x}*\setbox0=\hbox{x}*}

          where * marks a single space.

p. 105, l. 5:
        paragarph ->
        paragraph

p. 128, l. -22 (Exercise 5.21):
        Definiton ->
        Definition

p. 128, l. -18:
        .. such as French is used, where accented dotless \'i's are
        common ...

                French has no acute accent on the letter i, just a
                circumflex accent, and even that is rare, as in `ci
                g\^it Victor Hugo' on a tombstone.

                Turkish is an example of a language where there
                actually is a dotless i, but I don't know if Turkish
                uses accents. Pierre Mackay 
                is an expert on Turkish, and can provide further
                details.

p. 130, l. 8:
        |\def\abc ->
        \def\abc

p. 184, l. -1:
        at the Index ->
        look at the Index

p. 188, l. 20:
        be inserted ->
        are inserted

p. 219, l. -21:
        ... how the \tt commands was expanded ...
        to `\fam \ttfam \tentt', thereby ...

                The \tt command is NOT expanded this way in the .toc file
                shown on the next page

p. 240, l. 15--16:
        a \phantom can also be used for this purpose

                No: this is not the same as would be obtained with
                \rlap, because the text in the \phantom would be
                invisible in the output.

p. 271, l. 3:
        (page 5. ->
        (page 5).

p. 274, l. -12:
        pre ferred ->
        preferred

p. 275, l. -6:
        1984, edition ->
        1984 edition

p. 278, l. 14:
        When \pretolerance=0, the first pass will always fail.

                No, it will pass if the line has zero badness.

p. 296, l. 13:
        J\^orgen ->
        J\/orgen

p. 306, l. 6:
        \uvbox255 ->
        \unvbox255

p. 307, l. 6:
        Any nonzero register in this group is written on the .dvi file.

                No, all ten \count registers 0..9 are written on the
                .dvi file; see TeX: The Program, section 585, bop command.

p. 308, l. 15:
        3pc each, enough for about four lines of text. ->
        3pc each, enough for about three lines of text.

                3pc == 36pt; with a 10pt font and 12pt leading,
                three lines will take 10pt + 12pt + 12pt = 34pt; four
                lines would need 46pt.

p. 315, l. -4:
        which that the page ->
        which ...???... the page

                Text was apparently lost from the sentence here, but I
                don't know what the author intended to say.

p. 338, l. 12:
        OTRsimply ->
        OTR simply

p. 346, l. 9:
        Lines 1--19 ->
        Lines 1--16

        Lines 22--24 ->
        Lines 19--23

p. 346, l. 10:
        line 22, ->
        line 19,

p. 346, l. 15:
        line 9, ->
        line 8,

p. 346, l. 16:
        lines 12--15, ->
        lines 10--13

p. 347, l. 6:
        lines 27--29 ->
        lines 25--28

p. 348, l. -13 -- -12:
        The sp is necessary since, otherwise, the value of \lineno
        would be converted to scaled points.

                No, use of \lineno here would raise an error:

% tex
**\relax
*\newcount \lineno

*\lineno = 99

*\setbox0=\vbox{\vskip \lineno \relax}
! Illegal unit of measure (pt inserted).

                   \relax
<*> \setbox0=\vbox{\vskip \lineno \relax
                                        }

                Since \lineno is an integer, exactly one of the
                standard TeX dimension units must be supplied after
                \lineno to be acceptable as an argument to \vskip.

p. 353, l. 10,11:
        500sp ... 1000sp
                The first incorrectly uses {\tt sp} instead of {\rm sp}.

p. 354, l. 16:
        0--500sp
                The second incorrectly uses {\tt sp} instead of {\rm sp}.

p. 355, l. 16:
        and17.5 ->
        and 17.5

p. 358, l. -11 .. p. 359, l. 3:
                The dimensions 1sp and 2sp occur in font \tt; they should
                be in font \rm for consistency with the rest of the book.

p. 366, l. 14:
        Haralambous and the main ->
        Haralambous and is the main

p. 376, l. -11 -- -10:
        transcript file).'. ->
        transcript file).'.

p. 391, l. -4:
        #1#2 \strut ->
        #1#2\strut

                If the space is included here, it could be a place
                where a linebreak could occur in the footnote, which
                would force the struct onto the next line, and thereby
                make the footnote one line higher than it should be.

p. 392, l. -5:
        four footnote lines ->
        three footnote lines ->

                A value of 0.4in is 28.908pt; with the footnote
                set in 7pt text with \baselineskip = 8pt, n lines
                of text require 7 + (n-1)*8 points, or 8*n - 1 points;
                setting "8n - 1 = 28.908" and solving for n gives
                3.73850, which must be truncated to 3.

p. 425, l. 19:
        Here is its definition ->
        Here is its definition:

p. 437, l. 1:
        Pehong, C. ->
        Chen, P.
                Pehong is his given name, and Chen his family name.

        experience ->
        Experience
                [This capitalization is consistent with other entries
                in the bibliography.]

p. 456, l. 11:
        G. Lamaitre ->
        G. Lemaitre
                The word maitre is masculine, so unless this name
                is a horrid corruption of French grammar, it takes
                the masculine article, Le; I personally know someone 
                named Lemaitre.

p. 469, l. -13:
        The answers to the 10 exercise in chapter 17 are missing.
        The answers to exercises 19.2 -- 19.5 are omitted too, but
        the text warns on p. 410 of the omission; I find no such
        warning in Chapter 17.


p. 484, l. 11, column 1:
        count0 ->
        \count0
                [Use font \tt for this word!]

p. 484, l. 5, column 2:
        Pehong, C., 437 ->
        Chen, P., 437
                [and move this index entry to p. 473, column 2.]


========================================================================

Errors Contributed by Guenter Rote on 20 Dec 95.

Your claim that \hboxes or \vboxes with negative dimensions don't show in
print (p.38 top and p.45 bottom respectively) must be a misunderstanding.
You were probably thinking of rules. Also, I can set \ht0 \dp0 \wd0 to
any negative dimension I like.

The answer to exercise 8.7 is wrong. When you write \aste5, for example,
5 is a numeric quantity, but the number of asterisks printed will be the value
of \ctst. The correct answer is that
the macro \aste expects the number of stars to be printed in the counter
variable \ctst. (In fact, this is an example of bad programming practice.
Either remove the parameter: \def\aste{\ifnum \ctst>0...
or set \ctst=#1 inside \aste

An opposite case occurs on the bottom of p.117.
Why can you not just write
  \def\multbf #1{\if #1.\let\next=\relax
and continue with the rest of \actdef?
At least one can say that the use of futurelet is not sufficiently
motivated.

Your answer to exercise 3.51 does not give the intended box. (At least, the
solution is in general not rotation-symmetric.
the second \vrule should be raised by 2\dimen0.
In general, the quantity by which the second vrule is raised must be
by \dimen0 bigger than the quantity by which the first vrule is lowered.
Similarly, the second \hrule should be raised by 2\dimen0 instead of
\dimen0 + \thick.  (In your example, the last two quantities happen to be equal.

In Exercise 11.5, there is a larger gap between the first and second row than
between the remaining rows.

In section 5.11 you give bad examples of superfluous expandafters.
On p.123, in the first example there is no need to expand { before \jobname,
and thus 2 \expandafters can be omitted.
The example works even if all three \expandafters in the first line are
omitted, see section 2.6.
Similarly, on the opposite page \macB works just as well without \expandafter. (Why!)

On p.257 and also in 13.12 you seem to encourage the use of relation symbols
< and > for the inner product notation  of vectors.  From a mathematical
standpoint, the use of \langle and \rangle should be encouraged instead.

On page 118, after Ex. 5.8, the macro \boxt is described but not shown; on the
other hand, the reader should rather not try to type in the verbatim-text
above the two boxes.
You should have rather checked the contents carefully before "fine-tuning the
page and line breaks".

The text of section 19.4 is a quite verbatim copy of 16.3.

Although you use \mark and \botmark etc. in the book it is not explained.
(At least not in the places mentioned in the index.
\string is not in the index.

On p.320, section 16.14, I find that the situation is not well explained.
In the first proposed solution
   \shipout \vbox{\unvbox 255 \vfil},
the \vfil is indeed superfluous, but this solution does achieve a ragged
bottom. (It does not get rid of underfull vbox messages.

In \breakup on p.340, is there any point in copying the penalty to box 1
instead of simply ignoring it?

On top of p.397 you write: The reason for the failure is that \penalty does
not invoke the output routine immediately.
If the reason for the failure were really just this, it could be easily solved
by setting \global\Savedtrue directly in \endinsert instead of inserting the penalty.

p.288, line -14. TeX is not positioned before
                        'pt post error'
but before
                        'post error'

p.289, line -5 should be something like $\left( a+b \right)$
                                              ^           ^

I think your "magical" explanation on the bottom of p.107 is wrong.
This has to do nothing with mouth and stomach but with grouping.
Since endgraph is enclosed in { }, the automatic resetting of \parshape=0
is kept local, and parshape is set to its original values at the closing }.
You might try to insert showlists after \endgraf to check that the consecutive
paragraphs are not read as one paragraph.

Misprints: p. 263, line 4: latter->letter
p. 315, line -4
p.123, line -11, \token2 should be  and in a different font.
p. 158 line -4 catocde
p. 241: The page number is affected by font changes in the heading line,
because \firstmark on top of p.424 is not enclosed in braces.
Also the size in the section headings is not uniform. compare sections 12.2
with 17.8 or 6.4