Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
I know this is kind of esoteric, but this was the only thing that prevented me to cleanly ran
make
with php 8.1 on my 32-bit raspberry pi:I had to add 1G of swap to make it run without freezing the system, but this would in general make the build green on 32-bit. No idea if it's really worth pursuing though, but good to know at least, that right now, even without this fix, phpstan runs still just fine on 32-bit :)
The reason is that this test defines a numeric in a string that is bigger than PHP_INT_MAX, casts it to int and then string again. and the int cast behaves different, depending on PHP_INT_SIZE. https://3v4l.org/enuv2
Only doing that because in #693 some 32/64-bit questions came up. The only important thing, I'd say, is to still support scanning code made for 32-bit, phpstan doesn't have to run on 32-bit. But right know it still could, so I'm just trying to find an answer to the question if we still should support running it on 32-bit :) And if yes - how to make sure it stays like that? If not - is it fine to just drop the runtime support then?