diff options
author | Brett Cannon <bcannon@gmail.com> | 2008-05-09 05:18:40 +0000 |
---|---|---|
committer | Brett Cannon <bcannon@gmail.com> | 2008-05-09 05:18:40 +0000 |
commit | d7265d64831f870f46b7c61244b2c86dc803f292 (patch) | |
tree | 7c16633c07b27002f987e70296ade6c1b26a0601 /Lib/new.py | |
parent | d03238a6473cbf5d81d9d99c71e1bab36c3455d8 (diff) | |
download | cpython-git-d7265d64831f870f46b7c61244b2c86dc803f292.tar.gz |
Deprecate the new module for removal in 3.0.
Diffstat (limited to 'Lib/new.py')
-rw-r--r-- | Lib/new.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/new.py b/Lib/new.py index 1a5c11f2f3..e5f964f87e 100644 --- a/Lib/new.py +++ b/Lib/new.py @@ -3,9 +3,10 @@ This module is no longer required except for backward compatibility. Objects of most types can now be created by calling the type object. """ -from warnings import warnpy3k as _warnpy3k -_warnpy3k("The 'new' module is not supported in 3.x, use the 'types' module " - "instead.", stacklevel=2) +from warnings import warnpy3k +warnpy3k("The 'new' module has been removed in Python 3.0; use the 'types' " + "module instead.", stacklevel=2) +del warnpy3k from types import ClassType as classobj from types import FunctionType as function |