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

Skip to content

Commit 64c105d

Browse files
committed
Added index entries.
Small markup nits.
1 parent 0506a43 commit 64c105d

1 file changed

Lines changed: 8 additions & 5 deletions

File tree

Doc/lib/libimp.tex

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,9 @@ \section{\module{imp} ---
1212

1313

1414
\begin{funcdesc}{get_magic}{}
15+
\indexii{file}{byte-code}
1516
Return the magic string value used to recognize byte-compiled code
16-
files (``\code{.pyc} files''). (This value may be different for each
17+
files (\file{.pyc} files). (This value may be different for each
1718
Python version.)
1819
\end{funcdesc}
1920

@@ -22,8 +23,8 @@ \section{\module{imp} ---
2223
Each triple has the form \code{(\var{suffix}, \var{mode},
2324
\var{type})}, where \var{suffix} is a string to be appended to the
2425
module name to form the filename to search for, \var{mode} is the mode
25-
string to pass to the built-in \code{open} function to open the file
26-
(this can be \code{'r'} for text files or \code{'rb'} for binary
26+
string to pass to the built-in \function{open()} function to open the
27+
file (this can be \code{'r'} for text files or \code{'rb'} for binary
2728
files), and \var{type} is the file type, which has one of the values
2829
\constant{PY_SOURCE}, \constant{PY_COMPILED}, or
2930
\constant{C_EXTENSION}, described below.
@@ -167,6 +168,7 @@ \section{\module{imp} ---
167168
\end{funcdesc}
168169

169170
\begin{funcdesc}{load_compiled}{name, pathname, file}
171+
\indexii{file}{byte-code}
170172
Load and initialize a module implemented as a byte-compiled code file
171173
and return its module object. If the module was already initialized,
172174
it will be initialized \emph{again}. The \var{name} argument is used
@@ -200,8 +202,9 @@ \section{\module{imp} ---
200202
file, open for reading as text, from the beginning.
201203
It must currently be a real file
202204
object, not a user-defined class emulating a file. Note that if a
203-
properly matching byte-compiled file (with suffix \file{.pyc}) exists,
204-
it will be used instead of parsing the given source file.
205+
properly matching byte-compiled file (with suffix \file{.pyc} or
206+
\file{.pyo}) exists, it will be used instead of parsing the given
207+
source file.
205208
\end{funcdesc}
206209

207210

0 commit comments

Comments
 (0)