diff options
author | David Mitchell <davem@iabyn.com> | 2016-09-26 15:22:25 +0100 |
---|---|---|
committer | David Mitchell <davem@iabyn.com> | 2016-09-26 15:48:48 +0100 |
commit | d081a35540aca5feaa56d2ce8a0b72b909a2d79e (patch) | |
tree | b742f08de24ed3c9ac7759acc7621b2029f1616d /pad.h | |
parent | f2949f414d32db2fe5a59d82956b1cc4c693639f (diff) | |
download | perl-d081a35540aca5feaa56d2ce8a0b72b909a2d79e.tar.gz |
make PADOFFSET be SSizet_t
Currently it's defined as U32 or U64 depending on whether pointers are
32 bit or 64-bit, which is just a long-winded way of doing
typedef Size_t PADOFFSET
Change it to
typedef SSize_t PADOFFSET
Making it signed makes it easier to handle comparisons against PADOFFSET
values that can be -1, such as PL_comppad_name_floor (which will be fixed
in the next commit).
Diffstat (limited to 'pad.h')
-rw-r--r-- | pad.h | 8 |
1 files changed, 1 insertions, 7 deletions
@@ -18,13 +18,7 @@ /* offsets within a pad */ -#if PTRSIZE == 4 -typedef U32TYPE PADOFFSET; -#else -# if PTRSIZE == 8 -typedef U64TYPE PADOFFSET; -# endif -#endif +typedef SSize_t PADOFFSET; /* signed so that -1 is a valid value */ #define NOT_IN_PAD ((PADOFFSET) -1) /* B.xs expects the first members of these two structs to line up |