[Python-checkins] python/dist/src/Lib profile.py,1.48,1.49

rhettinger at users.sourceforge.net rhettinger at users.sourceforge.net
Wed Oct 22 12:49:04 EDT 2003


Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1:/tmp/cvs-serv14109

Modified Files:
	profile.py 
Log Message:
Replace a reduce() with sum().

Index: profile.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/profile.py,v
retrieving revision 1.48
retrieving revision 1.49
diff -C2 -d -r1.48 -r1.49
*** profile.py	27 Feb 2003 20:14:38 -0000	1.48
--- profile.py	22 Oct 2003 16:49:01 -0000	1.49
***************
*** 185,191 ****
                  # cases.
                  import operator
!                 def get_time_timer(timer=timer,
!                                    reduce=reduce, reducer=operator.add):
!                     return reduce(reducer, timer(), 0)
                  self.get_time = get_time_timer
          self.t = self.get_time()
--- 185,190 ----
                  # cases.
                  import operator
!                 def get_time_timer(timer=timer, sum=sum):
!                     return sum(timer())
                  self.get_time = get_time_timer
          self.t = self.get_time()





More information about the Python-checkins mailing list