Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes for 32-bit #3869

Merged
merged 2 commits into from
Jan 23, 2024
Merged

Fixes for 32-bit #3869

merged 2 commits into from
Jan 23, 2024

Conversation

oleibman
Copy link
Collaborator

I check from time to time. There are a number of problems now, mostly due to the elimination of Php 7.4 and replacement of doc-block typing with explicit Php typing.

  • Bitwise functions were particularly affected by PR Strengthen typing #3718 and PR Add all missing native types #3793.
  • Chart/Axis and Writer/Xlsx were amusingly affected by PR Chart Axis Display Units and Logarithmic Scale #3836, which added a scaling option which included an array indexed by the known allowable factors, one of which is 1 trillion, which cannot be represented as an integer on a 32-bit system. Issue3833Test, introduced by the same PR (and not suffering any errors) was expanded to test this value.
  • Some minor changes to Reader/Xls and Shared/OLE/PPS to accommodate hex values which are negative in 32-bit but which Php-32 may wind up casting to large floating point numbers; it is not clear to me why these hadn't shown up as problems previously. Possibly this is the result of changes in the most recent Php versions.
  • BitAndTest, BitOrTest, BitXorTest and Shared/DateTest were adversely affected by PR Better Typing in Test Members #3859 when arguments and/or expected results too large for a 32-bit integer were supplied.
  • ImExpTest required a slightly reduced precision for 32-bit. No idea why this hadn't shown up earlier.

This is:

  • a bugfix
  • a new feature
  • refactoring
  • additional unit tests

Checklist:

Why this change is needed?

Provide an explanation of why this change is needed, with links to any Issues (if appropriate).
If this is a bugfix or a new feature, and there are no existing Issues, then please also create an issue that will make it easier to track progress with this PR.

I check from time to time. There are a number of problems now, mostly due to the elimination of Php 7.4 and replacement of doc-block typing with explicit Php typing.
- Bitwise functions were particularly affected by PR PHPOffice#3718 and PR PHPOffice#3793.
- Chart/Axis and Writer/Xlsx were amusingly affected by PR PHPOffice#3836, which added a scaling option which included an array indexed by the known allowable factors, one of which is 1 trillion, which cannot be represented as an integer on a 32-bit system. Issue3833Test, introduced by the same PR (and not suffering any errors) was expanded to test this value.
- Some minor changes to Reader/Xls and Shared/OLE/PPS to accommodate hex values which are negative in 32-bit but which Php-32 may wind up casting to large floating point numbers; it is not clear to me why these hadn't shown up as problems previously. Possibly this is the result of changes in the most recent Php versions.
- BitAndTest, BitOrTest, BitXorTest and Shared/DateTest were adversely affected by PR PHPOffice#3859 when arguments and/or expected results too large for a 32-bit integer were supplied.
- ImExpTest required a slightly reduced precision for 32-bit. No idea why this hadn't shown up earlier.
@oleibman oleibman added this pull request to the merge queue Jan 23, 2024
Merged via the queue into PHPOffice:master with commit 570c86f Jan 23, 2024
14 checks passed
@oleibman oleibman deleted the bit32b branch January 23, 2024 04:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

1 participant