[Python-checkins] CVS: python/dist/src/Lib __future__.py,1.11,1.12
Tim Peters
tim_one@users.sourceforge.net
Thu, 23 Aug 2001 23:29:14 -0700
Update of /cvsroot/python/python/dist/src/Lib
In directory usw-pr-cvs1:/tmp/cvs-serv7657/python/Lib
Modified Files:
__future__.py
Log Message:
Back out trying to use the C values for CO_xxx.
__future__.py reverted to 1.9.
newmodule.c reverted to 2.32.
Index: __future__.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/__future__.py,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -d -r1.11 -r1.12
*** __future__.py 2001/08/19 05:29:25 1.11
--- __future__.py 2001/08/24 06:29:12 1.12
***************
*** 56,66 ****
__all__ = ["all_feature_names"] + all_feature_names
! try:
! import new as _new # for CO_xxx symbols
! except ImportError: # May happen during build
! class _new:
! CO_NESTED = 0x0010
! CO_GENERATOR_ALLOWED = 0x1000
! CO_FUTURE_DIVISION = 0x2000
class _Feature:
--- 56,66 ----
__all__ = ["all_feature_names"] + all_feature_names
! # The CO_xxx symbols are defined here under the same names used by
! # compile.h, so that an editor search will find them here. However,
! # they're not exported in __all__, because they don't really belong to
! # this module.
! CO_NESTED = 0x0010 # nested_scopes
! CO_GENERATOR_ALLOWED = 0x1000 # generators
! CO_FUTURE_DIVISION = 0x2000 # division
class _Feature:
***************
*** 93,103 ****
nested_scopes = _Feature((2, 1, 0, "beta", 1),
(2, 2, 0, "alpha", 0),
! _new.CO_NESTED)
generators = _Feature((2, 2, 0, "alpha", 1),
(2, 3, 0, "final", 0),
! _new.CO_GENERATOR_ALLOWED)
division = _Feature((2, 2, 0, "alpha", 2),
(3, 0, 0, "alpha", 0),
! _new.CO_FUTURE_DIVISION)
--- 93,103 ----
nested_scopes = _Feature((2, 1, 0, "beta", 1),
(2, 2, 0, "alpha", 0),
! CO_NESTED)
generators = _Feature((2, 2, 0, "alpha", 1),
(2, 3, 0, "final", 0),
! CO_GENERATOR_ALLOWED)
division = _Feature((2, 2, 0, "alpha", 2),
(3, 0, 0, "alpha", 0),
! CO_FUTURE_DIVISION)