[Python-checkins] r63236 - in python/trunk: Lib/plat-irix5/CL.py Lib/plat-irix5/CL_old.py Lib/plat-irix6/CL.py Lib/test/test_py3kwarn.py Misc/NEWS Modules/clmodule.c
brett.cannon
python-checkins at python.org
Wed May 14 23:12:13 CEST 2008
Author: brett.cannon
Date: Wed May 14 23:12:12 2008
New Revision: 63236
Log:
Deprecate CL, CL_old, and cl for 3.0.
Modified:
python/trunk/Lib/plat-irix5/CL.py
python/trunk/Lib/plat-irix5/CL_old.py
python/trunk/Lib/plat-irix6/CL.py
python/trunk/Lib/test/test_py3kwarn.py
python/trunk/Misc/NEWS
python/trunk/Modules/clmodule.c
Modified: python/trunk/Lib/plat-irix5/CL.py
==============================================================================
--- python/trunk/Lib/plat-irix5/CL.py (original)
+++ python/trunk/Lib/plat-irix5/CL.py Wed May 14 23:12:12 2008
@@ -1,5 +1,9 @@
# Backward compatible module CL.
# All relevant symbols are now defined in the module cl.
+from warnings import warnpy3k
+warnpy3k("the CL module has been removed in Python 3.0", stacklevel=2)
+del warnpy3k
+
try:
from cl import *
except ImportError:
Modified: python/trunk/Lib/plat-irix5/CL_old.py
==============================================================================
--- python/trunk/Lib/plat-irix5/CL_old.py (original)
+++ python/trunk/Lib/plat-irix5/CL_old.py Wed May 14 23:12:12 2008
@@ -8,6 +8,10 @@
#
# originalFormat parameter values
#
+from warnings import warnpy3k
+warnpy3k("the CL_old module has been removed in Python 3.0", stacklevel=2)
+del warnpy3k
+
MAX_NUMBER_OF_ORIGINAL_FORMATS = 32
# Audio
Modified: python/trunk/Lib/plat-irix6/CL.py
==============================================================================
--- python/trunk/Lib/plat-irix6/CL.py (original)
+++ python/trunk/Lib/plat-irix6/CL.py Wed May 14 23:12:12 2008
@@ -1,5 +1,9 @@
# Backward compatible module CL.
# All relevant symbols are now defined in the module cl.
+from warnings import warnpy3k
+warnpy3k("the CL module has been removed in Python 3.0", stacklevel=2)
+del warnpy3k
+
try:
from cl import *
except ImportError:
Modified: python/trunk/Lib/test/test_py3kwarn.py
==============================================================================
--- python/trunk/Lib/test/test_py3kwarn.py (original)
+++ python/trunk/Lib/test/test_py3kwarn.py Wed May 14 23:12:12 2008
@@ -132,7 +132,7 @@
'Bastion', 'compiler', 'dircache', 'fpformat',
'ihooks', 'mhlib')
inclusive_platforms = {'irix' : ('pure', 'AL', 'al', 'CD', 'cd', 'cddb',
- 'cdplayer'),
+ 'cdplayer', 'CL', 'cl'),
'darwin' : ('autoGIL', 'Carbon', 'OSATerminology',
'icglue', 'Nav', 'MacOS', 'aepack',
'aetools', 'aetypes', 'applesingle',
Modified: python/trunk/Misc/NEWS
==============================================================================
--- python/trunk/Misc/NEWS (original)
+++ python/trunk/Misc/NEWS Wed May 14 23:12:12 2008
@@ -32,6 +32,9 @@
Library
-------
+- The CL, CL_old, and cl modules for IRIX have been deprecated for removal in
+ Python 3.0.
+
- The cdplayer module for IRIX has been deprecated for removal in Python 3.0.
- The cddb module for IRIX has been deprecated for removal in Python 3.0.
Modified: python/trunk/Modules/clmodule.c
==============================================================================
--- python/trunk/Modules/clmodule.c (original)
+++ python/trunk/Modules/clmodule.c Wed May 14 23:12:12 2008
@@ -961,7 +961,11 @@
initcl(void)
{
PyObject *m, *d, *x;
-
+
+ if (PyErr_WarnPy3k("the cl module has been removed in "
+ "Python 3.0", 2) < 0)
+ return;
+
m = Py_InitModule("cl", cl_methods);
if (m == NULL)
return;
More information about the Python-checkins
mailing list