[Python-checkins] r82627 - sandbox/branches/py3k-datetime/datetime.py

alexander.belopolsky python-checkins at python.org
Wed Jul 7 19:59:55 CEST 2010


Author: alexander.belopolsky
Date: Wed Jul  7 19:59:55 2010
New Revision: 82627

Log:
Whitespace cleanup

Modified:
   sandbox/branches/py3k-datetime/datetime.py

Modified: sandbox/branches/py3k-datetime/datetime.py
==============================================================================
--- sandbox/branches/py3k-datetime/datetime.py	(original)
+++ sandbox/branches/py3k-datetime/datetime.py	Wed Jul  7 19:59:55 2010
@@ -13,7 +13,7 @@
 Sources for time zone and DST data: http://www.twinsun.com/tz/tz-link.htm
 
 This was originally copied from the sandbox of the CPython CVS repository.
-Thanks to Tim Peters for suggesting using it. 
+Thanks to Tim Peters for suggesting using it.
 """
 
 import time as _time
@@ -457,7 +457,7 @@
 
     def total_seconds(self):
         """Total seconds in the duration."""
-        return ((self.days * 86400 + self.seconds)*10**6 + 
+        return ((self.days * 86400 + self.seconds)*10**6 +
                 self.microseconds) / 10**6
 
     # Read-only field accessors
@@ -564,7 +564,7 @@
                           other._to_microseconds())
             return q, timedelta(0, 0, r)
         return NotImplemented
-        
+
     # Comparisons of timedelta objects with other.
 
     def __eq__(self, other):
@@ -1044,7 +1044,7 @@
         return self._hour
 
     @property
-    def minute(self): 
+    def minute(self):
         """minute (0-59)"""
         return self._minute
 
@@ -1052,7 +1052,7 @@
     def second(self):
         """second (0-59)"""
         return self._second
-    
+
     @property
     def microsecond(self):
         """microsecond (0-999999)"""
@@ -1332,7 +1332,7 @@
         return self._hour
 
     @property
-    def minute(self): 
+    def minute(self):
         """minute (0-59)"""
         return self._minute
 
@@ -1340,7 +1340,7 @@
     def second(self):
         """second (0-59)"""
         return self._second
-    
+
     @property
     def microsecond(self):
         """microsecond (0-999999)"""
@@ -1539,7 +1539,7 @@
         if L[-1] == 0:
             del L[-1]
         if L[-1] == 0:
-            del L[-1]            
+            del L[-1]
         s = ", ".join(map(str, L))
         s = "%s(%s)" % ('datetime.' + self.__class__.__name__, s)
         if self._tzinfo is not None:
@@ -1813,10 +1813,10 @@
 
     def __eq__(self, other):
         return self._offset == other._offset
-    
+
     def __hash__(self):
         return hash(self._offset)
-    
+
     def __repr__(self):
         """Convert to formal string, for repr().
 
@@ -1857,7 +1857,7 @@
             return None
         raise TypeError("dst() argument must be a datetime instance"
                         " or None")
-    
+
     def fromutc(self, dt):
         if isinstance(dt, datetime):
             if dt.tzinfo is not self:
@@ -2082,4 +2082,3 @@
 perverse time zone returns a negative dst()).  So a breaking case must be
 pretty bizarre, and a tzinfo subclass can override fromutc() if it is.
 """
-


More information about the Python-checkins mailing list