[Python-checkins] r88173 - in python/branches/release31-maint: Doc/library/ast.rst Doc/library/tkinter.tix.rst Lib/ast.py

terry.reedy python-checkins at python.org
Mon Jan 24 22:46:05 CET 2011


Author: terry.reedy
Date: Mon Jan 24 22:46:05 2011
New Revision: 88173

Log:
Issue #11000 ast.parse doc fix (r88172) + tix fix (r88170)


Modified:
   python/branches/release31-maint/Doc/library/ast.rst
   python/branches/release31-maint/Doc/library/tkinter.tix.rst
   python/branches/release31-maint/Lib/ast.py

Modified: python/branches/release31-maint/Doc/library/ast.rst
==============================================================================
--- python/branches/release31-maint/Doc/library/ast.rst	(original)
+++ python/branches/release31-maint/Doc/library/ast.rst	Mon Jan 24 22:46:05 2011
@@ -107,9 +107,9 @@
 Apart from the node classes, :mod:`ast` module defines these utility functions
 and classes for traversing abstract syntax trees:
 
-.. function:: parse(expr, filename='<unknown>', mode='exec')
+.. function:: parse(source, filename='<unknown>', mode='exec')
 
-   Parse an expression into an AST node.  Equivalent to ``compile(expr,
+   Parse the source into an AST node.  Equivalent to ``compile(source,
    filename, mode, ast.PyCF_ONLY_AST)``.
 
 

Modified: python/branches/release31-maint/Doc/library/tkinter.tix.rst
==============================================================================
--- python/branches/release31-maint/Doc/library/tkinter.tix.rst	(original)
+++ python/branches/release31-maint/Doc/library/tkinter.tix.rst	Mon Jan 24 22:46:05 2011
@@ -503,8 +503,8 @@
 
    To view the current settings, the common usage is::
 
-      import Tix
-      root = Tix.Tk()
+      from tkinter import tix
+      root = tix.Tk()
       print(root.tix_configure())
 
 

Modified: python/branches/release31-maint/Lib/ast.py
==============================================================================
--- python/branches/release31-maint/Lib/ast.py	(original)
+++ python/branches/release31-maint/Lib/ast.py	Mon Jan 24 22:46:05 2011
@@ -29,12 +29,12 @@
 from _ast import __version__
 
 
-def parse(expr, filename='<unknown>', mode='exec'):
+def parse(source, filename='<unknown>', mode='exec'):
     """
-    Parse an expression into an AST node.
-    Equivalent to compile(expr, filename, mode, PyCF_ONLY_AST).
+    Parse the source into an AST node.
+    Equivalent to compile(source, filename, mode, PyCF_ONLY_AST).
     """
-    return compile(expr, filename, mode, PyCF_ONLY_AST)
+    return compile(source, filename, mode, PyCF_ONLY_AST)
 
 
 def literal_eval(node_or_string):


More information about the Python-checkins mailing list