Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
ff2a4ba7
Commit
ff2a4ba7
authored
Nov 30, 2010
by
Éric Araujo
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Let’s keep “throw” for the generator method and use “raise” elsewhere.
parent
827fdaae
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
4 additions
and
4 deletions
+4
-4
Doc/library/configparser.rst
Doc/library/configparser.rst
+1
-1
Doc/library/os.rst
Doc/library/os.rst
+1
-1
Doc/library/parser.rst
Doc/library/parser.rst
+1
-1
Doc/library/urllib.parse.rst
Doc/library/urllib.parse.rst
+1
-1
No files found.
Doc/library/configparser.rst
View file @
ff2a4ba7
...
...
@@ -320,7 +320,7 @@ However, there are a few differences that should be taken into account:
the default value to be visible again. Trying to delete a default value
causes a ``KeyError``.
* Trying to delete the ``DEFAULTSECT``
throw
s ``ValueError``.
* Trying to delete the ``DEFAULTSECT``
raise
s ``ValueError``.
* There are two parser-level methods in the legacy API that hide the dictionary
interface and are incompatible:
...
...
Doc/library/os.rst
View file @
ff2a4ba7
...
...
@@ -1150,7 +1150,7 @@ Files and Directories
single: UNC paths; and os.makedirs()
Recursive directory creation function. Like :func:`mkdir`, but makes all
intermediate-level directories needed to contain the leaf directory.
Throw
s
intermediate-level directories needed to contain the leaf directory.
Raise
s
an :exc:`error` exception if the leaf directory already exists or cannot be
created. The default *mode* is ``0o777`` (octal). On some systems, *mode*
is ignored. Where it is used, the current umask value is first masked out.
...
...
Doc/library/parser.rst
View file @
ff2a4ba7
...
...
@@ -268,7 +268,7 @@ function for information about the exceptions it can raise.
will only need to be aware of the simple string values.
Note that the functions :func:`compilest`, :func:`expr`, and :func:`suite` may
raise exceptions which are normally
thrown
by the parsing and compilation
raise exceptions which are normally
raised
by the parsing and compilation
process. These include the built in exceptions :exc:`MemoryError`,
:exc:`OverflowError`, :exc:`SyntaxError`, and :exc:`SystemError`. In these
cases, these exceptions carry all the meaning normally associated with them.
...
...
Doc/library/urllib.parse.rst
View file @
ff2a4ba7
...
...
@@ -283,7 +283,7 @@ passed in, the result will contain only :class:`bytes` data.
Attempting to mix :class:`str` data with :class:`bytes` or
:class:`bytearray` in a single function call will result in a
:exc:`TypeError` being
thrown
, while attempting to pass in non-ASCII
:exc:`TypeError` being
raised
, while attempting to pass in non-ASCII
byte values will trigger :exc:`UnicodeDecodeError`.
To support easier conversion of result objects between :class:`str` and
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment