Timothy S. Nelson wrote:
On Tue, 17 Feb 2009, Darren Duncan wrote:
Second of all, I think a more generic term than DateTime should be used to name an object that represents an instant in time; for example I suggest calling it "Instant". The name "Instant" fits in a lot better in the company of other generic sounding temporal data types like "Duration" etc. Then, you can say that things like DateTime, Date, Time, etc are subtypes of Instant.

Love the name; I'll do the rename as soon as the Spec reorganisation is sorted out.

Great to hear.  It took me a bit of effort back in September to come up with it.

And by the way, potentially another good word would have been Moment except that this word is often used by physics people to mean either of several different things than an instant in time. Instant didn't seem to have that problem of there being possibly confused other uses.

It also means that we can use DateTime to refer to Instant+Duration+... :).

You could.

Or why not use "Temporal" if you want a broader category or namespace? That's the most generic term I can think of that accurately applies and that it would be easy for people to understand at a moment's glance.

(It is also a lot easier to think up in the first place than Instant but was too broad for the latter's use.)

And using single word names for things where they fit is a lot more elegant I think, and is also in keeping with the Perl way of built-ins tending to all have single word names.

Save "Date" and "Time" for more specific things rather than more general things.

Also, calling something "DateTime" smells, like it was a fall-back because it was difficult to come up with a single word. It smells like having a numeric type and calling it "WholeFraction" rather than "Number" or "Rational".

Thank you. -- Darren Duncan

Reply via email to