Michael Pliskin a écrit :
Hello Neko,

  I am going to add some simple APIs to Neko to allow converting
  between local time and GMT time. I have two ways of doing that:
   - write two more functions: date_get_gmt_day and date_get_gmt_time,
     accepting an int32 and returning corresponding day-month-year and
     hour-min-sec structures
   - write another two functions: date_local_to_gmt and
     date_gmt_to_local, accepting and returning int32's.

Hi Michael,

I tend to prefer the second option, because it's more flexible.
It also doesn't prevent any highlevel API (such as haXe) to use it in a safer manner.

While you're at it, please look if you have some time the possibilities of getting/setting the TimeZone, that might be useful for people working with international times.

Best,
Nicolas

--
Neko : One VM to run them all
(http://nekovm.org)

Reply via email to