Repository navigation
Conversation
|
Note : apparently needs adaptation with higher branches. |
ndossche
left a comment
There was a problem hiding this comment.
This is more or less right: recurrences is an int in _php_period_obj so we can't store a higher number. The issue isn't fully solved though because if include_start_date and include_end_date are set then you still get an integer overflow because you can add 2 to INT_MAX.
|
From a technical PoV this is right and stops the undefined behaviour. |
|
in fact I tried to separate to let know of the second edge case separately but yes it s not so urgent anyway we ll see :). |
There was a problem hiding this comment.
between 1 is ambiguous between > 1 or >= 1. Please be precise.
There was a problem hiding this comment.
That's standard wording (and always refers to the closed interval). cc @Girgias
There was a problem hiding this comment.
We have always used it to mean an inclusive range AFAIK.
Might help to have helper functions for this, similar to what I did for ValueErrors which are empty.
There was a problem hiding this comment.
should I revert back to the previous wording ?
There was a problem hiding this comment.
I think this is superfluous. Doesn't the test run fine on 32bit platforms, too?
There was a problem hiding this comment.
I do not recall why, usually I do not disable for 32 bits just like this. I ll give it a go in a bit later.
There was a problem hiding this comment.
seems working indeed, might had been just a case I forgot to remove after code changes.
|
This should not be applied to PHP-8.2 any longer. |
|
Ah good point, time flies :) |
There was a problem hiding this comment.
I don't know why you removed the specific extension here? We had an RFC for this:
There was a problem hiding this comment.
ok I see, going to fix these..
There was a problem hiding this comment.
nit: No need to add empty lines
There was a problem hiding this comment.
Also use the specific extension here again.
There was a problem hiding this comment.
Please add the exception class, like in the other tests, by using:
echo $e::class, ': ', echo $e->getMessage() . PHP_EOL;
derickr
left a comment
There was a problem hiding this comment.
LGTM, but please address my last nit. And then also please squash before merging.
There was a problem hiding this comment.
nit: extraneous line at end of file
No description provided.