summaryrefslogtreecommitdiffstats
path: root/Lib/new.py
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2008-05-09 05:18:40 (GMT)
committerBrett Cannon <bcannon@gmail.com>2008-05-09 05:18:40 (GMT)
commitd7265d64831f870f46b7c61244b2c86dc803f292 (patch)
tree7c16633c07b27002f987e70296ade6c1b26a0601 /Lib/new.py
parentd03238a6473cbf5d81d9d99c71e1bab36c3455d8 (diff)
downloadcpython-d7265d64831f870f46b7c61244b2c86dc803f292.zip
cpython-d7265d64831f870f46b7c61244b2c86dc803f292.tar.gz
cpython-d7265d64831f870f46b7c61244b2c86dc803f292.tar.bz2
Deprecate the new module for removal in 3.0.
Diffstat (limited to 'Lib/new.py')
-rw-r--r--Lib/new.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/new.py b/Lib/new.py
index 1a5c11f..e5f964f 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