-
Notifications
You must be signed in to change notification settings - Fork 542
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix some 32/64-bit compiler warnings
Some bits of code don't do well on a 32-bit system with 64-bit ints (-Duse64bitint) In particular: _MEM_WRAP_NEEDS_RUNTIME_CHECK: if sizeof(MEM_SIZE) > sizeof(n), then the shift count could be negative S_regmatch: ln and n were two different sizes and signesses, so comparing them warned. Since they were being mis-used as two convenient temporary booleans anyway, just use temporary booleans instead. Perl_sv_vcatpvfn_flags: the test/assertion (IV)elen < 0 was (I think) being used to test for signed/unsigned conversion wrap-around. elen is of type STRLEN which is a pointer-based type, so can be 32-bit while IV is 64-bit. Instead compare it to half the maximum value of a STRLEN var to see if it may have wrapped.
- Loading branch information
Showing
3 changed files
with
40 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters