diff options
author | Georg Brandl <georg@python.org> | 2007-12-02 09:40:06 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2007-12-02 09:40:06 (GMT) |
commit | 1a3284ed69d545e4ef59869998cb8c29233a45fa (patch) | |
tree | 98728a9b7aae6188ee8124160007a9d5c5277f8c /Doc/tutorial | |
parent | 87f9c53937ce47f55851ac7c71a94e46cf9142bf (diff) | |
download | cpython-1a3284ed69d545e4ef59869998cb8c29233a45fa.zip cpython-1a3284ed69d545e4ef59869998cb8c29233a45fa.tar.gz cpython-1a3284ed69d545e4ef59869998cb8c29233a45fa.tar.bz2 |
#1535: rename __builtin__ module to builtins.
Diffstat (limited to 'Doc/tutorial')
-rw-r--r-- | Doc/tutorial/classes.rst | 2 | ||||
-rw-r--r-- | Doc/tutorial/modules.rst | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst index 4e95419..577c7e9 100644 --- a/Doc/tutorial/classes.rst +++ b/Doc/tutorial/classes.rst @@ -98,7 +98,7 @@ until the interpreter quits. The statements executed by the top-level invocation of the interpreter, either read from a script file or interactively, are considered part of a module called :mod:`__main__`, so they have their own global namespace. (The built-in names actually also live in a module; this is -called :mod:`__builtin__`.) +called :mod:`builtins`.) The local namespace for a function is created when the function is called, and deleted when the function returns or raises an exception that is not handled diff --git a/Doc/tutorial/modules.rst b/Doc/tutorial/modules.rst index 4d8b48f..2a14b35 100644 --- a/Doc/tutorial/modules.rst +++ b/Doc/tutorial/modules.rst @@ -308,14 +308,14 @@ Without arguments, :func:`dir` lists the names you have defined currently:: Note that it lists all types of names: variables, modules, functions, etc. -.. index:: module: __builtin__ +.. index:: module: builtins :func:`dir` does not list the names of built-in functions and variables. If you want a list of those, they are defined in the standard module -:mod:`__builtin__`:: +:mod:`builtins`:: - >>> import __builtin__ - >>> dir(__builtin__) + >>> import builtins + >>> dir(builtins) ['ArithmeticError', 'AssertionError', 'AttributeError', 'BaseException', 'Buffer Error', 'DeprecationWarning', 'EOFError', 'Ellipsis', 'EnvironmentError', 'Excep |