Skip to content

Conversation

devnexen
Copy link
Member

@devnexen devnexen commented Oct 5, 2024

No description provided.

zend_long year, golden, solar, lunar, pfm, dom, tmp, easter, result;
zend_long method = CAL_EASTER_DEFAULT;
const zend_long max_year = ZEND_LONG_MAX / 1.25;
const zend_long max_year = (zend_long)((double)ZEND_LONG_MAX / 1.25);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not

Suggested change
const zend_long max_year = (zend_long)((double)ZEND_LONG_MAX / 1.25);
const zend_long max_year = (ZEND_LONG_MAX / 5) * 4;

Copy link
Member

@cmb69 cmb69 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think the cast to zend_long is necessary, but it doesn't really hurt.

@devnexen devnexen closed this in 6d9903f Oct 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants