3 >Synopsis: infinite loops for shorthands
4 >Arrival-Date: Tue May 12 15:51:11 1998
5 >Originator: TeX@vvv.vsu.ru ( Vladimir Volovich )
6 >Release: LaTeX2e <1997/12/01> patch level 1
10 Under some circumstances, BABEL goes into infinite loop when some
11 shorthands are defined. The attached test file demonstrates this. The
12 loop occurs on a second run of latex, when the TOC file is being read.
13 I used `english' option to BABEL to be independent of any other files
14 (so the meaning of defining a shorthand !` in english is not important
15 here). The infinite loop disappears as soon as one uncomments a line
16 `\declare@shorthand{system}{!}{\string!}'. Probably, this is not a bug
17 but is a `feature', and one should always define system level shorthands
18 to avoid loops, so I'm sorry if this is the case.
20 This file demonstrates how such a thing should be defined; it works
21 with both babel 3.6 and 3.7
26 \documentclass{article}
29 \FORMAT{LaTeX2e<1997/12/01>}
31 \AUTHOR{TeX@vvv.vsu.ru ( Vladimir Volovich )}
32 \PACKAGE[english]{babel}
35 \usepackage[english]{babel}
38 \initiate@active@char{!}
39 \addto\extrasenglish{\languageshorthands{english}}
40 \addto\extrasenglish{\bbl@activate{!}}
41 \addto\noextrasenglish{\bbl@deactivate{!}}
42 \declare@shorthand{english}{!`}{\UseTextSymbol{OT1}{\textexclamdown}}
43 \declare@shorthand{system}{!}{\string!}
49 \showboxbreadth=90\showboxdepth=90
50 \setbox0\vbox{\@parboxrestore
53 \section{This is a test!`!{}{}{}}
54 \subsection{This is a test!`!{}{}{}}}