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

Skip to content

Commit ea81edf

Browse files
committed
Markup nits.
Fixed an index entry, added three more.
1 parent 1475e88 commit ea81edf

1 file changed

Lines changed: 15 additions & 10 deletions

File tree

Doc/ref/ref5.tex

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ \subsection{Identifiers (Names)\label{atom-identifiers}}
8282
\indexii{private}{names}%
8383
when an identifier that textually occurs in a class definition begins
8484
with two or more underscore characters and does not end in two or more
85-
underscores, it is considered a ``private name'' of that class.
85+
underscores, it is considered a \dfn{private name} of that class.
8686
Private names are transformed to a longer form before code is
8787
generated for them. The transformation inserts the class name in
8888
front of the name, with leading underscores removed, and a single
@@ -356,9 +356,14 @@ \subsection{Slicings\label{slicings}}
356356
expression is that expression. The conversion of an ellipsis slice
357357
item is the built-in \code{Ellipsis} object. The conversion of a
358358
proper slice is a slice object (see section \ref{types}) whose
359-
\code{start}, \code{stop} and \code{step} attributes are the values of
360-
the expressions given as lower bound, upper bound and stride,
361-
respectively, substituting \code{None} for missing expressions.
359+
\member{start}, \member{stop} and \member{step} attributes are the
360+
values of the expressions given as lower bound, upper bound and
361+
stride, respectively, substituting \code{None} for missing
362+
expressions.
363+
\withsubitem{(slice object attribute)}{%
364+
\ttindex{start}%
365+
\ttindex{stop}%
366+
\ttindex{step}}
362367

363368
\subsection{Calls\label{calls}}
364369
\index{call}
@@ -409,23 +414,23 @@ \subsection{Calls\label{calls}}
409414

410415
If there are more positional arguments than there are formal parameter
411416
slots, a \exception{TypeError} exception is raised, unless a formal
412-
parameter using the syntax ``\code{*identifier}'' is present; in this
417+
parameter using the syntax \samp{*identifier} is present; in this
413418
case, that formal parameter receives a tuple containing the excess
414419
positional arguments (or an empty tuple if there were no excess
415420
positional arguments).
416421

417422
If any keyword argument does not correspond to a formal parameter
418423
name, a \exception{TypeError} exception is raised, unless a formal
419-
parameter using the syntax ``\code{**identifier}'' is present; in this
424+
parameter using the syntax \samp{**identifier} is present; in this
420425
case, that formal parameter receives a dictionary containing the
421426
excess keyword arguments (using the keywords as keys and the argument
422427
values as corresponding values), or a (new) empty dictionary if there
423428
were no excess keyword arguments.
424429

425-
Formal parameters using the syntax ``\code{*identifier}'' or
426-
``\code{**identifier}'' cannot be used as positional argument slots or
430+
Formal parameters using the syntax \samp{*identifier} or
431+
\samp{**identifier} cannot be used as positional argument slots or
427432
as keyword argument names. Formal parameters using the syntax
428-
``\code{(sublist)}'' cannot be used as keyword argument names; the
433+
\samp{(sublist)} cannot be used as keyword argument names; the
429434
outermost sublist corresponds to a single unnamed argument slot, and
430435
the argument value is assigned to the sublist using the usual tuple
431436
assignment rules after all other parameter processing is done.
@@ -475,7 +480,7 @@ \subsection{Calls\label{calls}}
475480
\item[a class instance:] The class must define a \method{__call__()}
476481
method; the effect is then the same as if that method was called.
477482
\indexii{instance}{call}
478-
\ttindex{__call__}
483+
\withsubitem{(object method)}{\ttindex{__call__()}}
479484

480485
\end{description}
481486

0 commit comments

Comments
 (0)