[Zope-Checkins] CVS: Zope/lib/python/DateTime - DateTime.py:1.87

Andreas Jung andreas at andreas-jung.com
Tue Oct 21 09:09:07 EDT 2003


Update of /cvs-repository/Zope/lib/python/DateTime
In directory cvs.zope.org:/tmp/cvs-serv24545/lib/python/DateTime

Modified Files:
	DateTime.py 
Log Message:

     - Collector #951: DateTime(None) now raises a proper SyntaxError


=== Zope/lib/python/DateTime/DateTime.py 1.86 => 1.87 ===
--- Zope/lib/python/DateTime/DateTime.py:1.86	Thu Jul 17 15:06:12 2003
+++ Zope/lib/python/DateTime/DateTime.py	Tue Oct 21 09:09:06 2003
@@ -632,10 +632,11 @@
         ac=len(args)
         millisecs = None
 
-        if ac and args[0]==None: return
+        if ac and args[0]==None: 
+            raise self.SyntaxError, None
         elif ac==10:
             # Internal format called only by DateTime
-            yr,mo,dy,hr,mn,sc,tz,t,d,s=args
+            yr,mo,dy,hr,mn,sc,tz,t,d,s=args                  
         elif ac == 11:
             # Internal format that includes milliseconds.
             yr,mo,dy,hr,mn,sc,tz,t,d,s,millisecs=args




More information about the Zope-Checkins mailing list