SetDate is strange
  • Order of the Butterfly
    Order of the Butterfly
    polluks
    Posts: 438 from 2007/10/23
    From: Gelsenkirchen,...
    SetDate is future and List is past, why?

    Code:
    Ram Disk:> date
    Monday 24-Jun-19 19:04:10
    Ram Disk:> date 22-jun-19
    Ram Disk:> touch foo
    Ram Disk:> date 24-jun-19
    Ram Disk:> list foo
    foo empty ----rwed Saturday 19:04:38
    1 file - 0 bytes used
    Ram Disk:> setdate foo Saturday
    Ram Disk:> list foo
    foo empty ----rwed 29-Jun-19 19:04:58
    1 file - 0 bytes used
    Pegasos II G4: MorphOS 3.9, Zalman M220W · iMac G5 12,1
    Power Mac G3: OSX 10.3 · PowerBook 5,8: OSX 10.5, MorphOS 3.11
  • »24.06.19 - 21:27
    Profile
  • MorphOS Developer
    jacadcaps
    Posts: 1801 from 2003/3/5
    From: Poland
    Thanks for reporting. The problem's been fixed for 3.12.
  • »25.06.19 - 12:43
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    Jeckel
    Posts: 133 from 2007/3/11
    Weren't future dates shown as "future" in AmigaOS?
  • »25.06.19 - 13:06
    Profile
  • Order of the Butterfly
    Order of the Butterfly
    polluks
    Posts: 438 from 2007/10/23
    From: Gelsenkirchen,...
    Quote:

    jacadcaps schrieb:
    Thanks for reporting. The problem's been fixed for 3.12.

    I see, only SetDate and Date use following flag.

    Code:
    		DTF_FUTURE:	  If set, indicates that strings such
    as (stored in dat_StrDate) "Monday"
    refer to "next" monday. Otherwise,
    if clear, strings like "Monday"
    refer to "last" monday.
    Pegasos II G4: MorphOS 3.9, Zalman M220W · iMac G5 12,1
    Power Mac G3: OSX 10.3 · PowerBook 5,8: OSX 10.5, MorphOS 3.11
  • »25.06.19 - 16:52
    Profile
  • MorphOS Developer
    Piru
    Posts: 403 from 2003/2/24
    From: finland, the l...
    Quote:

    jacadcaps wrote:
    Thanks for reporting. The problem's been fixed for 3.12.


    To be precise the reported issue itself is not fixed. It works as intended (albeit it is a bit confusing how it is).

    However, the original report made me realize that there was another bug: DateToStr with DTF_SUBST didn't use "Future" for dates beyond "Tomorrow". That bug will be fixed for 3.12.
  • »25.06.19 - 18:55
    Profile
  • MorphOS Developer
    Piru
    Posts: 403 from 2003/2/24
    From: finland, the l...
    Quote:

    Jeckel wrote:
    Weren't future dates shown as "future" in AmigaOS?


    Yes. And they will be in 3.12+ too. :)
  • »25.06.19 - 18:57
    Profile