diff options
author | Antoine Pitrou <solipsis@pitrou.net> | 2011-01-08 09:55:31 (GMT) |
---|---|---|
committer | Antoine Pitrou <solipsis@pitrou.net> | 2011-01-08 09:55:31 (GMT) |
commit | 67b212e608044b094272248200db71af69518df9 (patch) | |
tree | 672383dd6eff6fd4c88d515288ac170bb7c0026a /Lib/contextlib.py | |
parent | d97b7b5158ce3149d4fc7d45a1d8af694ef3564c (diff) | |
download | cpython-67b212e608044b094272248200db71af69518df9.zip cpython-67b212e608044b094272248200db71af69518df9.tar.gz cpython-67b212e608044b094272248200db71af69518df9.tar.bz2 |
Issue #10859: Make `contextlib.GeneratorContextManager` officially
private by renaming it to `_GeneratorContextManager`.
Diffstat (limited to 'Lib/contextlib.py')
-rw-r--r-- | Lib/contextlib.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Lib/contextlib.py b/Lib/contextlib.py index e37fde8..4633cff 100644 --- a/Lib/contextlib.py +++ b/Lib/contextlib.py @@ -17,7 +17,7 @@ class ContextDecorator(object): return inner -class GeneratorContextManager(ContextDecorator): +class _GeneratorContextManager(ContextDecorator): """Helper for @contextmanager decorator.""" def __init__(self, gen): @@ -92,7 +92,7 @@ def contextmanager(func): """ @wraps(func) def helper(*args, **kwds): - return GeneratorContextManager(func(*args, **kwds)) + return _GeneratorContextManager(func(*args, **kwds)) return helper |