Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #64691

Re: datetime as subclass of date

References <CANc-5Uw5z84=vAMVJaCH-KCSR=1q8_zTKuspaF2zzOG9qtVu4Q@mail.gmail.com> <mailman.5913.1390515296.18130.python-list@python.org> <roy-29B820.19102323012014@news.panix.com> <85lhy5g999.fsf@benfinney.id.au>
Date 2014-01-24 10:03 -0600
Subject Re: datetime as subclass of date
From Skip Montanaro <skip@pobox.com>
Newsgroups comp.lang.python
Message-ID <mailman.5946.1390579404.18130.python-list@python.org> (permalink)

Show all headers | View raw


One thing that always reinforced my notion that
issubclass(datetime.datetime, datetime.date) should be False is that
the presence of of date and time methods gives me a mental image of
delegation, not inheritance. That is, it "feels" like a datetime
object is the aggregation of a date object and a time object, not a
specialized date object with some added time machinery mixed in.

Skip

Back to comp.lang.python | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

Re: datetime as subclass of date Ben Finney <ben+python@benfinney.id.au> - 2014-01-24 09:14 +1100
  Re: datetime as subclass of date Roy Smith <roy@panix.com> - 2014-01-23 19:10 -0500
    Re: datetime as subclass of date Ben Finney <ben+python@benfinney.id.au> - 2014-01-24 17:54 +1100
    Re: datetime as subclass of date Skip Montanaro <skip@pobox.com> - 2014-01-24 10:03 -0600

csiph-web