From 54356499be5a2405878e732254c88ba5e14163e0 Mon Sep 17 00:00:00 2001 From: Jaysin Shukla Date: Thu, 2 Mar 2017 16:34:44 +0530 Subject: [PATCH] [FIX] Fixing spelling mistakes in documentation. --- Doc/distributing/index.rst | 4 ++-- Doc/distutils/apiref.rst | 6 +++--- Doc/distutils/builtdist.rst | 4 ++-- Doc/distutils/introduction.rst | 2 +- Doc/distutils/sourcedist.rst | 2 +- Doc/extending/extending.rst | 4 ++-- Doc/extending/newtypes.rst | 12 ++++++------ Doc/tutorial/classes.rst | 2 +- Doc/tutorial/datastructures.rst | 4 ++-- Doc/tutorial/floatingpoint.rst | 4 ++-- Doc/tutorial/modules.rst | 2 +- Doc/using/cmdline.rst | 6 +++--- Doc/using/windows.rst | 2 +- 13 files changed, 27 insertions(+), 27 deletions(-) diff --git a/Doc/distributing/index.rst b/Doc/distributing/index.rst index 82ecd2c1ef45fbe..3d48b464960d145 100644 --- a/Doc/distributing/index.rst +++ b/Doc/distributing/index.rst @@ -23,7 +23,7 @@ installing other Python projects, refer to the .. note:: For corporate and other institutional users, be aware that many - organisations have their own policies around using and contributing to + organizations have their own policies around using and contributing to open source software. Please take such policies into account when making use of the distribution and installation tools provided with Python. @@ -82,7 +82,7 @@ reasonably straightforward for developers to make their own contributions back to that common pool of software if they choose to do so. The same distribution tools can also be used to distribute software within -an organisation, regardless of whether that software is published as open +an organization, regardless of whether that software is published as open source software or not. diff --git a/Doc/distutils/apiref.rst b/Doc/distutils/apiref.rst index b5b7731074c2ca3..049ebf490c6dced 100644 --- a/Doc/distutils/apiref.rst +++ b/Doc/distutils/apiref.rst @@ -209,7 +209,7 @@ the full reference. | | on Unix C compiler command | | | | line) | | +------------------------+--------------------------------+---------------------------+ - | *undef_macros* | list of macros to undefine | a list of strings | + | *undef_macros* | list of macros to undefined | a list of strings | | | explicitly | | +------------------------+--------------------------------+---------------------------+ | *library_dirs* | list of directories to search | a list of strings | @@ -322,7 +322,7 @@ This module provides the following functions. Generate C pre-processor options (:option:`!-D`, :option:`!-U`, :option:`!-I`) as used by at least two types of compilers: the typical Unix compiler and Visual C++. *macros* is the usual thing, a list of 1- or 2-tuples, where ``(name,)`` - means undefine (:option:`!-U`) macro *name*, and ``(name, value)`` means define + means undefined (:option:`!-U`) macro *name*, and ``(name, value)`` means define (:option:`!-D`) macro *name* to *value*. *include_dirs* is just a list of directory names to be added to the header file search path (:option:`!-I`). Returns a list of command-line options suitable for either Unix compilers or @@ -1746,7 +1746,7 @@ Subclasses of :class:`Command` must define the following methods. .. method:: Command.run() - A command's raison d'etre: carry out the action it exists to perform, controlled + A command's raising d'etre: carry out the action it exists to perform, controlled by the options initialized in :meth:`initialize_options`, customized by other commands, the setup script, the command-line, and config files, and finalized in :meth:`finalize_options`. All terminal output and filesystem interaction should diff --git a/Doc/distutils/builtdist.rst b/Doc/distutils/builtdist.rst index bbd2a8ce831cee1..d796c6fea75a3e0 100644 --- a/Doc/distutils/builtdist.rst +++ b/Doc/distutils/builtdist.rst @@ -373,7 +373,7 @@ system will need to use Visual Studio 2008 to open the extensions is possible. Note that by default, Visual Studio 2008 does not install 64bit compilers or -tools. You may need to reexecute the Visual Studio setup process and select +tools. You may need to re execute the Visual Studio setup process and select these tools (using Control Panel->[Add/Remove] Programs is a convenient way to check or modify your existing install.) @@ -404,7 +404,7 @@ built-in functions in the installation script. file_created(path) These functions should be called when a directory or file is created by the - postinstall script at installation time. It will register *path* with the + post install script at installation time. It will register *path* with the uninstaller, so that it will be removed when the distribution is uninstalled. To be safe, directories are only removed if they are empty. diff --git a/Doc/distutils/introduction.rst b/Doc/distutils/introduction.rst index 8f46bd74c5b01a1..83617b85e100fdc 100644 --- a/Doc/distutils/introduction.rst +++ b/Doc/distutils/introduction.rst @@ -150,7 +150,7 @@ operating from a common starting point, we offer the following glossary of common Python terms: module - the basic unit of code reusability in Python: a block of code imported by some + the basic unit of code re usability in Python: a block of code imported by some other code. Three types of modules concern us here: pure Python modules, extension modules, and packages. diff --git a/Doc/distutils/sourcedist.rst b/Doc/distutils/sourcedist.rst index cc289c9b2551cbd..3c7d125ce6a0b72 100644 --- a/Doc/distutils/sourcedist.rst +++ b/Doc/distutils/sourcedist.rst @@ -174,7 +174,7 @@ Following the Distutils' own manifest template, let's trace how the source distribution: #. include all Python source files in the :file:`distutils` and - :file:`distutils/command` subdirectories (because packages corresponding to + :file:`distutils/command` sub-directories (because packages corresponding to those two directories were mentioned in the ``packages`` option in the setup script---see section :ref:`setup-script`) diff --git a/Doc/extending/extending.rst b/Doc/extending/extending.rst index 4ac820a432b9b01..efe574ae609e704 100644 --- a/Doc/extending/extending.rst +++ b/Doc/extending/extending.rst @@ -186,7 +186,7 @@ Finally, be careful to clean up garbage (by making :c:func:`Py_XDECREF` or :c:func:`Py_DECREF` calls for objects you have already created) when you return an error indicator! -The choice of which exception to raise is entirely yours. There are predeclared +The choice of which exception to raise is entirely yours. There are pre-declared C objects corresponding to all built-in Python exceptions, such as :c:data:`PyExc_ZeroDivisionError`, which you can use directly. Of course, you should choose exceptions wisely --- don't use :c:data:`PyExc_TypeError` to mean @@ -898,7 +898,7 @@ Reference Counting in Python ---------------------------- There are two macros, ``Py_INCREF(x)`` and ``Py_DECREF(x)``, which handle the -incrementing and decrementing of the reference count. :c:func:`Py_DECREF` also +increment and decrement of the reference count. :c:func:`Py_DECREF` also frees the object when the count reaches zero. For flexibility, it doesn't call :c:func:`free` directly --- rather, it makes a call through a function pointer in the object's :dfn:`type object`. For this purpose (and others), every object diff --git a/Doc/extending/newtypes.rst b/Doc/extending/newtypes.rst index 118f336ae11deb3..90754a899f35f20 100644 --- a/Doc/extending/newtypes.rst +++ b/Doc/extending/newtypes.rst @@ -130,7 +130,7 @@ our objects and in some error messages, for example:: Note that the name is a dotted name that includes both the module name and the name of the type within the module. The module in this case is :mod:`noddy` and the type is :class:`Noddy`, so we set the type name to :class:`noddy.Noddy`. -One side effect of using an undotted name is that the pydoc documentation tool +One side effect of using an un-dotted name is that the pydoc documentation tool will not list the new type in the module documentation. :: sizeof(noddy_NoddyObject), /* tp_basicsize */ @@ -682,7 +682,7 @@ enables these slots: .. literalinclude:: ../includes/noddy4.c -The traversal method provides access to subobjects that could participate in +The traversal method provides access to sub-objects that could participate in cycles:: static int @@ -704,9 +704,9 @@ cycles:: return 0; } -For each subobject that can participate in cycles, we need to call the +For each sub-object that can participate in cycles, we need to call the :c:func:`visit` function, which is passed to the traversal method. The -:c:func:`visit` function takes as arguments the subobject and the extra argument +:c:func:`visit` function takes as arguments the sub-object and the extra argument *arg* passed to the traversal method. It returns an integer value that must be returned if it is non-zero. @@ -727,8 +727,8 @@ functions. With :c:func:`Py_VISIT`, :c:func:`Noddy_traverse` can be simplified: *visit* and *arg* in order to use :c:func:`Py_VISIT`. This is to encourage uniformity across these boring implementations. -We also need to provide a method for clearing any subobjects that can -participate in cycles. We implement the method and reimplement the deallocator +We also need to provide a method for clearing any sub-objects that can +participate in cycles. We implement the method and re-implement the deallocator to use it:: static int diff --git a/Doc/tutorial/classes.rst b/Doc/tutorial/classes.rst index e134d5d62ea667d..d5d2c0deafc7612 100644 --- a/Doc/tutorial/classes.rst +++ b/Doc/tutorial/classes.rst @@ -274,7 +274,7 @@ assigned to, so you can change the value of ``MyClass.i`` by assignment. the class: ``"A simple example class"``. Class *instantiation* uses function notation. Just pretend that the class -object is a parameterless function that returns a new instance of the class. +object is a parameter-less function that returns a new instance of the class. For example (assuming the above class):: x = MyClass() diff --git a/Doc/tutorial/datastructures.rst b/Doc/tutorial/datastructures.rst index 6140ece046b9754..4bce71186c27d78 100644 --- a/Doc/tutorial/datastructures.rst +++ b/Doc/tutorial/datastructures.rst @@ -67,7 +67,7 @@ objects: Raises a :exc:`ValueError` if there is no such item. The optional arguments *start* and *end* are interpreted as in the slice - notation and are used to limit the search to a particular subsequence of + notation and are used to limit the search to a particular sub-sequence of the list. The returned index is computed relative to the beginning of the full sequence rather than the *start* argument. @@ -192,7 +192,7 @@ List Comprehensions List comprehensions provide a concise way to create lists. Common applications are to make new lists where each element is the result of some operations applied to each member of another sequence or iterable, or to -create a subsequence of those elements that satisfy a certain condition. +create a sub-sequence of those elements that satisfy a certain condition. For example, assume we want to create a list of squares, like:: diff --git a/Doc/tutorial/floatingpoint.rst b/Doc/tutorial/floatingpoint.rst index 0c0eb526fa9ed60..bdf9d4613137156 100644 --- a/Doc/tutorial/floatingpoint.rst +++ b/Doc/tutorial/floatingpoint.rst @@ -75,7 +75,7 @@ of digits manageable by displaying a rounded value instead :: 0.1 Just remember, even though the printed result looks like the exact value -of 1/10, the actual stored value is the nearest representable binary fraction. +of 1/10, the actual stored value is the nearest re-presentable binary fraction. Interestingly, there are many different decimal numbers that share the same nearest approximate binary fraction. For example, the numbers ``0.1`` and @@ -217,7 +217,7 @@ decimal fractions cannot be represented exactly as binary (base 2) fractions. This is the chief reason why Python (or Perl, C, C++, Java, Fortran, and many others) often won't display the exact decimal number you expect. -Why is that? 1/10 is not exactly representable as a binary fraction. Almost all +Why is that? 1/10 is not exactly re-presentable as a binary fraction. Almost all machines today (November 2000) use IEEE-754 floating point arithmetic, and almost all platforms map Python floats to IEEE-754 "double precision". 754 doubles contain 53 bits of precision, so on input the computer strives to diff --git a/Doc/tutorial/modules.rst b/Doc/tutorial/modules.rst index 1e3d5c01a47adf5..ebba039163b50e2 100644 --- a/Doc/tutorial/modules.rst +++ b/Doc/tutorial/modules.rst @@ -206,7 +206,7 @@ automatic process. Also, the compiled modules are platform-independent, so the same library can be shared among systems with different architectures. Python does not check the cache in two circumstances. First, it always -recompiles and does not store the result for the module that's loaded directly +re-compiles and does not store the result for the module that's loaded directly from the command line. Second, it does not check the cache if there is no source module. To support a non-source (compiled only) distribution, the compiled module must be in the source directory, and there must not be a source diff --git a/Doc/using/cmdline.rst b/Doc/using/cmdline.rst index 195f63f0a319da9..93c4d12a64356c5 100644 --- a/Doc/using/cmdline.rst +++ b/Doc/using/cmdline.rst @@ -92,7 +92,7 @@ source. This option cannot be used with built-in modules and extension modules written in C, since they do not have Python module files. However, it - can still be used for precompiled modules, even if the original source + can still be used for pre-compiled modules, even if the original source file is not available. If this option is given, the first element of :data:`sys.argv` will be the @@ -246,12 +246,12 @@ Miscellaneous options .. cmdoption:: -O - Turn on basic optimizations. See also :envvar:`PYTHONOPTIMIZE`. + Turn on basic optimization. See also :envvar:`PYTHONOPTIMIZE`. .. cmdoption:: -OO - Discard docstrings in addition to the :option:`-O` optimizations. + Discard docstrings in addition to the :option:`-O` optimization. .. cmdoption:: -q diff --git a/Doc/using/windows.rst b/Doc/using/windows.rst index 3e4b70e8a17ef7e..6d152412dbb5431 100644 --- a/Doc/using/windows.rst +++ b/Doc/using/windows.rst @@ -254,7 +254,7 @@ choose "Uninstall/Change" to open the installer in maintenance mode. "Modify" allows you to add or remove features by modifying the checkboxes - unchanged checkboxes will not install or remove anything. Some options cannot be changed in this mode, such as the install directory; to modify these, you will -need to remove and then reinstall Python completely. +need to remove and then re-install Python completely. "Repair" will verify all the files that should be installed using the current settings and replace any that have been removed or modified.