This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Patch for LONG_MAX & co.
authorPerl 5 Porters <perl5-porters@africa.nicoh.com>
Sun, 1 Sep 1996 22:35:00 +0000 (22:35 +0000)
committerAndy Dougherty <doughera@lafcol.lafayette.edu>
Sun, 1 Sep 1996 22:35:00 +0000 (22:35 +0000)
commit27d4fb967e484643f49397f430300f14a7bf480b
treeaadfed7105066240f5140343216967ab95326896
parentf812a825ad11ccc7750b0eabdad6859d214a048a
Patch for LONG_MAX & co.

Sorry about adding yet another #ifdef forest, but hopefully this
should resolve the *_MAX issues permanently. It adds to the
previously defined PERL_LONG_MAX, PERL_LONG_MIN, and PERL_ULONG_MAX
symbols the complete set of
/PERL_U?(CHAR|SHORT|INT|LONG)_(MAX|MIN)/, and installs aliases to
those from /(I|U)(8|16|32|V)_(MAX|MIN)/ so that for any standard
Perl typedef, like I32 or UV, you can reference I32_MAX or UV_MIN,
and get appropriate figures. All references to LONG_(MIN|MAX) are
changed appropriately.

The .c changes have the side effect of making cast_uv properly use quad
limits if quads are in use, but longs aren't 64 bit. Hopefully this all
works, but I don't have any handy Crays to try it out on.

Add notes on perl's internal types, specifically Quad_t and IV.
handy.h
perl.h