Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 020f8c0

Browse files
committed
Make sure chapters, sections, and subsections all have a \label to give them
semantic file names in the HTML version; no more node#.html files. Fix one section heading.
1 parent 1a7bab0 commit 020f8c0

1 file changed

Lines changed: 25 additions & 23 deletions

File tree

Doc/ref/ref5.tex

Lines changed: 25 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
\chapter{Expressions}
1+
\chapter{Expressions\label{expressions}}
22
\index{expression}
33

44
This chapter explains the meaning of the elements of expressions in
@@ -16,7 +16,7 @@ \chapter{Expressions}
1616
are the same as for \code{othername}.
1717
\index{syntax}
1818

19-
\section{Arithmetic conversions}
19+
\section{Arithmetic conversions\label{conversions}}
2020
\indexii{arithmetic}{conversion}
2121

2222
When a description of an arithmetic operator below uses the phrase
@@ -39,7 +39,9 @@ \section{Arithmetic conversions}
3939
Some additional rules apply for certain operators (e.g., a string left
4040
argument to the `\%' operator). Extensions can define their own
4141
coercions.
42-
\section{Atoms}
42+
43+
44+
\section{Atoms\label{atoms}}
4345
\index{atom}
4446

4547
Atoms are the most basic elements of expressions. The simplest atoms
@@ -52,7 +54,7 @@ \section{Atoms}
5254
enclosure: parenth_form|list_display|dict_display|string_conversion
5355
\end{verbatim}
5456

55-
\subsection{Identifiers (Names)}
57+
\subsection{Identifiers (Names)\label{atom-identifiers}}
5658
\index{name}
5759
\index{identifier}
5860

@@ -92,7 +94,7 @@ \subsection{Identifiers (Names)}
9294
implementation defined truncation may happen. If the class name
9395
consists only of underscores, no transformation is done.
9496

95-
\subsection{Literals}
97+
\subsection{Literals\label{atom-literals}}
9698
\index{literal}
9799

98100
Python supports string literals and various numeric literals:
@@ -115,7 +117,7 @@ \subsection{Literals}
115117
\indexiii{immutable}{data}{type}
116118
\indexii{immutable}{objects}
117119

118-
\subsection{Parenthesized forms}
120+
\subsection{Parenthesized forms\label{parenthesized}}
119121
\index{parenthesized form}
120122

121123
A parenthesized form is an optional expression list enclosed in
@@ -143,7 +145,7 @@ \subsection{Parenthesized forms}
143145
\index{comma}
144146
\indexii{tuple}{display}
145147

146-
\subsection{List displays}
148+
\subsection{List displays\label{lists}}
147149
\indexii{list}{display}
148150

149151
A list display is a possibly empty series of expressions enclosed in
@@ -160,7 +162,7 @@ \subsection{List displays}
160162
\obindex{list}
161163
\indexii{empty}{list}
162164

163-
\subsection{Dictionary displays} \label{dict}
165+
\subsection{Dictionary displays\label{dict}}
164166
\indexii{dictionary}{display}
165167

166168
A dictionary display is a possibly empty series of key/datum pairs
@@ -189,7 +191,7 @@ \subsection{Dictionary displays} \label{dict}
189191
stored for a given key value prevails.
190192
\indexii{immutable}{objects}
191193

192-
\subsection{String conversions}
194+
\subsection{String conversions\label{string-conversions}}
193195
\indexii{string}{conversion}
194196
\indexii{reverse}{quotes}
195197
\indexii{backward}{quotes}
@@ -228,7 +230,7 @@ \subsection{String conversions}
228230
\bifuncindex{repr}
229231
\bifuncindex{str}
230232

231-
\section{Primaries} \label{primaries}
233+
\section{Primaries\label{primaries}}
232234
\index{primary}
233235

234236
Primaries represent the most tightly bound operations of the language.
@@ -238,7 +240,7 @@ \section{Primaries} \label{primaries}
238240
primary: atom | attributeref | subscription | slicing | call
239241
\end{verbatim}
240242

241-
\subsection{Attribute references}
243+
\subsection{Attribute references\label{attribute-references}}
242244
\indexii{attribute}{reference}
243245

244246
An attribute reference is a primary followed by a period and a name:
@@ -258,7 +260,7 @@ \subsection{Attribute references}
258260
\obindex{module}
259261
\obindex{list}
260262

261-
\subsection{Subscriptions}
263+
\subsection{Subscriptions\label{subscriptions}}
262264
\index{subscription}
263265

264266
A subscription selects an item of a sequence (string, tuple or list)
@@ -295,7 +297,7 @@ \subsection{Subscriptions}
295297
\index{character}
296298
\indexii{string}{item}
297299

298-
\subsection{Slicings}
300+
\subsection{Slicings\label{slicings}}
299301
\index{slicing}
300302
\index{slice}
301303

@@ -358,7 +360,7 @@ \subsection{Slicings}
358360
the expressions given as lower bound, upper bound and stride,
359361
respectively, substituting \code{None} for missing expressions.
360362

361-
\subsection{Calls} \label{calls}
363+
\subsection{Calls\label{calls}}
362364
\index{call}
363365

364366
A call calls a callable object (e.g., a function) with a possibly empty
@@ -478,7 +480,7 @@ \subsection{Calls} \label{calls}
478480
\end{description}
479481

480482

481-
\section{The power operator}
483+
\section{The power operator\label{power}}
482484

483485
The power operator binds more tightly than unary operators on its
484486
left; it binds less tightly than unary operators on its right. The
@@ -502,7 +504,7 @@ \section{The power operator}
502504
\exception{TypeError} exception is raised.
503505

504506

505-
\section{Unary arithmetic operations}
507+
\section{Unary arithmetic operations\label{unary}}
506508
\indexiii{unary}{arithmetic}{operation}
507509
\indexiii{unary}{bit-wise}{operation}
508510

@@ -531,7 +533,7 @@ \section{Unary arithmetic operations}
531533
a \exception{TypeError} exception is raised.
532534
\exindex{TypeError}
533535

534-
\section{Binary arithmetic operations}
536+
\section{Binary arithmetic operations\label{binary}}
535537
\indexiii{binary}{arithmetic}{operation}
536538

537539
The binary arithmetic operations have the conventional priority
@@ -594,7 +596,7 @@ \section{Binary arithmetic operations}
594596
type.
595597
\index{subtraction}
596598

597-
\section{Shifting operations}
599+
\section{Shifting operations\label{shifting}}
598600
\indexii{shifting}{operation}
599601

600602
The shifting operations have lower priority than the arithmetic
@@ -618,7 +620,7 @@ \section{Shifting operations}
618620
exception.
619621
\exindex{ValueError}
620622

621-
\section{Binary bit-wise operations}
623+
\section{Binary bit-wise operations\label{bitwise}}
622624
\indexiii{binary}{bit-wise}{operation}
623625

624626
Each of the three bitwise operations has a different priority level:
@@ -646,7 +648,7 @@ \section{Binary bit-wise operations}
646648
\indexii{bit-wise}{or}
647649
\indexii{inclusive}{or}
648650

649-
\section{Comparisons}
651+
\section{Comparisons\label{comparisons}}
650652
\index{comparison}
651653

652654
Contrary to \C, all comparison operations in Python have the same
@@ -749,7 +751,7 @@ \section{Comparisons}
749751
\opindex{is not}
750752
\indexii{identity}{test}
751753

752-
\section{Boolean operations} \label{Booleans}
754+
\section{Boolean operations\label{Booleans}}
753755
\indexii{Boolean}{operation}
754756

755757
Boolean operations have the lowest priority of all Python operations:
@@ -821,7 +823,7 @@ \section{Boolean operations} \label{Booleans}
821823
return lambda x, n=increment: x+n
822824
\end{verbatim}
823825

824-
\section{Expression lists and expression lists}
826+
\section{Expression lists\label{exprlists}}
825827
\indexii{expression}{list}
826828

827829
\begin{verbatim}
@@ -841,7 +843,7 @@ \section{Expression lists and expression lists}
841843
\code{()}.)
842844
\indexii{trailing}{comma}
843845

844-
\section{Summary}
846+
\section{Summary\label{summary}}
845847

846848
The following table summarizes the operator precedences in Python,
847849
from lowest precedence (least binding) to highest precedence (most

0 commit comments

Comments
 (0)