[Python-checkins] python/dist/src/Lib ConfigParser.py,1.41,1.42 dis.py,1.38,1.39

rhettinger@users.sourceforge.net rhettinger@users.sourceforge.net
2002年5月31日 17:57:57 -0700


Update of /cvsroot/python/python/dist/src/Lib
In directory usw-pr-cvs1:/tmp/cvs-serv29718
Modified Files:
	ConfigParser.py dis.py 
Log Message:
Replaced boolean test with 'is None'
Index: ConfigParser.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/ConfigParser.py,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -d -r1.41 -r1.42
*** ConfigParser.py	26 Apr 2002 02:29:55 -0000	1.41
--- ConfigParser.py	1 Jun 2002 00:57:55 -0000	1.42
***************
*** 271,275 ****
 d.update(sectdict)
 # Update with the entry specific variables
! if vars:
 d.update(vars)
 option = self.optionxform(option)
--- 271,275 ----
 d.update(sectdict)
 # Update with the entry specific variables
! if vars is not None:
 d.update(vars)
 option = self.optionxform(option)
Index: dis.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/dis.py,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -d -r1.38 -r1.39
*** dis.py	11 Feb 2002 18:14:22 -0000	1.38
--- dis.py	1 Jun 2002 00:57:55 -0000	1.39
***************
*** 14,18 ****
 
 """
! if not x:
 distb()
 return
--- 14,18 ----
 
 """
! if x is None:
 distb()
 return
***************
*** 45,49 ****
 def distb(tb=None):
 """Disassemble a traceback (default: last traceback)."""
! if not tb:
 try:
 tb = sys.last_traceback
--- 45,49 ----
 def distb(tb=None):
 """Disassemble a traceback (default: last traceback)."""
! if tb is None:
 try:
 tb = sys.last_traceback
***************
*** 313,322 ****
 else:
 fn = None
! if not fn:
 f = sys.stdin
 else:
 f = open(fn)
 source = f.read()
! if fn:
 f.close()
 else:
--- 313,322 ----
 else:
 fn = None
! if fn is None:
 f = sys.stdin
 else:
 f = open(fn)
 source = f.read()
! if fn is not None:
 f.close()
 else:

AltStyle によって変換されたページ (->オリジナル) /