Year current previous error

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Year current previous error

GLASS mailing list
Ciao,

i found this problematic when i used this code in the year 2016 :

Year current previous 

It use the Timespan previous  method 

 ^self class starting: ( start - duration) duration: duration 

but because duration into 2016 is 366 days it return year instance starting at 31 - 12 - 2014 with duration set to 365 days ( end at 30 - 12 - 2015 )


I copy into GLASS  the Pharo Year  previous implementation:

previous "This implementation handles leap years correctly" ^ self class year: (self year - 1)


and all works fine.


Question :  

who and when include this code into GLASS distribution system ?

I can do something about it ?

Thanks,

Dario




_______________________________________________
Glass mailing list
[hidden email]
http://lists.gemtalksystems.com/mailman/listinfo/glass
Reply | Threaded
Open this post in threaded view
|

Re: Year current previous error

GLASS mailing list
Thanks Dario,

I've submitted an issue[1] and I will update glassdb shortly...

Dale


[1] https://github.com/GsDevKit/GsDevKit/issues/86

On 01/05/2016 06:43 AM, Trussardi Dario Romano via Glass wrote:
because duration into 2016 is 366 days it return year instance starting at 31 - 12 - 2014 with duration set to 365 days ( end at 30 - 12 - 2015 )


I copy into GLASS  the Pharo Year  previous implementation:

previous "This implementation handles leap years correctly" ^ self class year: (self year - 1)


and all works fine.


_______________________________________________
Glass mailing list
[hidden email]
http://lists.gemtalksystems.com/mailman/listinfo/glass
Reply | Threaded
Open this post in threaded view
|

Re: Year current previous error

GLASS mailing list
Bugfix is available on gladddb/glass master branch[1]

[1] https://github.com/glassdb/glass/pull/8

On 01/05/2016 10:31 AM, Dale Henrichs wrote:
Thanks Dario,

I've submitted an issue[1] and I will update glassdb shortly...

Dale


[1] https://github.com/GsDevKit/GsDevKit/issues/86

On 01/05/2016 06:43 AM, Trussardi Dario Romano via Glass wrote:
because duration into 2016 is 366 days it return year instance starting at 31 - 12 - 2014 with duration set to 365 days ( end at 30 - 12 - 2015 )


I copy into GLASS  the Pharo Year  previous implementation:

previous "This implementation handles leap years correctly" ^ self class year: (self year - 1)


and all works fine.



_______________________________________________
Glass mailing list
[hidden email]
http://lists.gemtalksystems.com/mailman/listinfo/glass