Next version of Date, DateAndTime, and Duration API updates

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

Next version of Date, DateAndTime, and Duration API updates

cbc
Now in the InBox:
   KernelTests-cbc.278.mcz
   Kernel-cbc.871.mcz
The tests add in test for expected Duration addition and subtraction from each other, including the new GenericMonth and GenericYear, and the very new GenericDuration.  It also adds a few more tests for LeapYear tests with adding years to them.

The test are still based on what it currently does, with the exceptions listed previously (I haven't really changed any to expect failures, as has been suggested - that will come shortly.  For now, I want to try to cause little to no changes o expected behavior first - just new behavior for now).

Kernel adds the GenericDuration, and handles adding and subtracting GenericMonth, GenericYear, and GenericDurations togeher in a rational way.  This involves turning + and - in Durations into a double-dispatch so that it will work.

There are no comments  yet in these classes - they will be there before the weekend is over at the latest.

Any comments are more than welcome.

-cbc


Reply | Threaded
Open this post in threaded view
|

Re: Next version of Date, DateAndTime, and Duration API updates

Bert Freudenberg

On 19.09.2014, at 08:29, Chris Cunningham <[hidden email]> wrote:

> Now in the InBox:
>    KernelTests-cbc.278.mcz
>    Kernel-cbc.871.mcz
> The tests add in test for expected Duration addition and subtraction from each other, including the new GenericMonth and GenericYear, and the very new GenericDuration.  It also adds a few more tests for LeapYear tests with adding years to them.
>
> The test are still based on what it currently does, with the exceptions listed previously (I haven't really changed any to expect failures, as has been suggested - that will come shortly.  For now, I want to try to cause little to no changes o expected behavior first - just new behavior for now).
>
> Kernel adds the GenericDuration, and handles adding and subtracting GenericMonth, GenericYear, and GenericDurations togeher in a rational way.  This involves turning + and - in Durations into a double-dispatch so that it will work.
>
> There are no comments  yet in these classes - they will be there before the weekend is over at the latest.
>
> Any comments are more than welcome.
Just eyeballing the code it looked okay.

You still need to implement #hash since you implemented #= (when two objects are equal they must answer the same hash).

- Bert -




smime.p7s (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Next version of Date, DateAndTime, and Duration API updates

Chris Muller-3
In reply to this post by cbc
Let us know when you feel its ready for full-on testing.  I'll pull
them in and run some regression tests.


On Fri, Sep 19, 2014 at 1:29 AM, Chris Cunningham
<[hidden email]> wrote:

> Now in the InBox:
>    KernelTests-cbc.278.mcz
>    Kernel-cbc.871.mcz
> The tests add in test for expected Duration addition and subtraction from
> each other, including the new GenericMonth and GenericYear, and the very new
> GenericDuration.  It also adds a few more tests for LeapYear tests with
> adding years to them.
>
> The test are still based on what it currently does, with the exceptions
> listed previously (I haven't really changed any to expect failures, as has
> been suggested - that will come shortly.  For now, I want to try to cause
> little to no changes o expected behavior first - just new behavior for now).
>
> Kernel adds the GenericDuration, and handles adding and subtracting
> GenericMonth, GenericYear, and GenericDurations togeher in a rational way.
> This involves turning + and - in Durations into a double-dispatch so that it
> will work.
>
> There are no comments  yet in these classes - they will be there before the
> weekend is over at the latest.
>
> Any comments are more than welcome.
>
> -cbc
>
>
>

cbc
Reply | Threaded
Open this post in threaded view
|

Re: Next version of Date, DateAndTime, and Duration API updates

cbc
Ok. I certainly will do so.

On Fri, Sep 19, 2014 at 12:10 PM, Chris Muller <[hidden email]> wrote:
Let us know when you feel its ready for full-on testing.  I'll pull
them in and run some regression tests.


On Fri, Sep 19, 2014 at 1:29 AM, Chris Cunningham
<[hidden email]> wrote:
> Now in the InBox:
>    KernelTests-cbc.278.mcz
>    Kernel-cbc.871.mcz
> The tests add in test for expected Duration addition and subtraction from
> each other, including the new GenericMonth and GenericYear, and the very new
> GenericDuration.  It also adds a few more tests for LeapYear tests with
> adding years to them.
>
> The test are still based on what it currently does, with the exceptions
> listed previously (I haven't really changed any to expect failures, as has
> been suggested - that will come shortly.  For now, I want to try to cause
> little to no changes o expected behavior first - just new behavior for now).
>
> Kernel adds the GenericDuration, and handles adding and subtracting
> GenericMonth, GenericYear, and GenericDurations togeher in a rational way.
> This involves turning + and - in Durations into a double-dispatch so that it
> will work.
>
> There are no comments  yet in these classes - they will be there before the
> weekend is over at the latest.
>
> Any comments are more than welcome.
>
> -cbc
>
>
>