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
0269f67d
Commit
0269f67d
authored
Jan 08, 2008
by
Georg Brandl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix markup errors from r59857 and clarify key.__enter__/__exit__ docs
parent
6c503809
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
11 deletions
+16
-11
Doc/library/_winreg.rst
Doc/library/_winreg.rst
+16
-11
No files found.
Doc/library/_winreg.rst
View file @
0269f67d
...
...
@@ -136,11 +136,11 @@ This module offers the following functions:
.. function:: ExpandEnvironmentStrings(unicode)
Expands environment strings %NAME% in unicode string like const:`REG_EXPAND_SZ`::
>>> ExpandEnvironmentStrings(u"%windir%")
u"C:\\Windows"
.. versionadded: 2.6
>>> ExpandEnvironmentStrings(u"%windir%")
u"C:\\Windows"
.. versionadded:
:
2.6
.. function:: FlushKey(key)
...
...
@@ -429,10 +429,15 @@ handle, and also disconnect the Windows handle from the handle object.
underlying Win32 handle to exist beyond the lifetime of the handle object.
.. method:: PyHKEY.__enter__()
.. method:: PyHKEY.__exit__(*exc_info)
The HKEY object implements __enter__ and __exit__ and thus supports the
context protocol for the with statement.
.. versionadded: 2.6
PyHKEY.__exit__(\*exc_info)
The HKEY object implements :meth:`__enter__` and :meth:`__exit__` and thus
supports the context protocol for the :keyword:`with` statement::
with OpenKey(HKEY_LOCAL_MACHINE, "foo") as key:
# ... work with key ...
will automatically close *key* when control leaves the :keyword:`with` block.
.. versionadded:: 2.6
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