[squeak-dev] Testing membership in a Set of Date objects

David T. Lewis lewis at mail.msen.com
Sat Oct 20 15:17:23 UTC 2018


Hi Tim,

On Fri, Oct 19, 2018 at 06:13:10PM -0700, Tim Johnson wrote:
> 
> 
> > On Oct 19, 2018, at 10:52 AM, Chris Cunningham <cunningham.cb at gmail.com> wrote:
> > 
> > (in a Workspace)
> > | dates |
> > dates := Set newFrom: ( { Date yesterday. Date tomorrow.  DateAndTime now asDate } collect: #stripTimezone ).
> > dates includes: (Date year: 2018 month: 10 day: 19). "true"
> > dates asOrderedCollection includes: (Date year: 2018 month: 10 day: 19). "true"
> > 
> > Would it be convenient for you to try out the proposed Chronology fix in your case (with or without the #stripTimezone), and report back if this works well for you?  I'd like to make dates work like we all think they should.
> 
> Hi Chris,
> 
> Thanks to you and Chris M. and company.  I was excited to try this out today but got sucked into a spinning vortex of unexpected messes.
> 
> It seemed in a separate thread that folks might be leaning toward crafting a different solution at the moment...?
> 
> In any case, my project makes heavy use of Timespan, DateAndTime, and Date, so I believe it will be a good test subject.  My working image stayed at work so I won't be returning to it until Monday, and it held abundant data to test with.  But I did push my project up to GitHub, and as such could try it out over the weekend ??? I'll just be missing all the data.
> 

Yes you're right, there are two different threads. This one is about
fixing an an important issue in the current Squeak 5.2 release.

The other discussion concerns UTCDateAndTime:

http://lists.squeakfoundation.org/pipermail/squeak-dev/2018-October/200322.html

This is something we are considering bringing into trunk for Squeak 5.3
and beyond. It's a big enough change that it would be good to bring it
in early in the release cycle, hence the discussion now.

If you could try UTCDateAndTime with your project and see if it causes
any issues for you, that would be a huge help.

You can install UTCDateAndTime into a Squeak 5.2 image from the SqueakMap
loader. Please be sure to use a copy of your image when you do this,
because the changes are easy to install but nearly impossible to remove.

Thanks in advance, I would really appreciate getting some real-world
feedback on this :-)

Dave



More information about the Squeak-dev mailing list