Skip to content

[doc] Size of IV & UV in perlguts & perl.h #18995

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

Open
FGasper opened this issue Jul 21, 2021 · 2 comments
Open

[doc] Size of IV & UV in perlguts & perl.h #18995

FGasper opened this issue Jul 21, 2021 · 2 comments

Comments

@FGasper
Copy link
Contributor

FGasper commented Jul 21, 2021

Where

perlguts describes IV as:

guaranteed to be large enough to hold a pointer (as well as an integer)

… which sounds a lot like the description of intmax_t:

A signed integer type capable of representing any value of any signed integer type.

These sound like system-wide things, but in actual implementation the size of IV and UV vary with Perl’s configuration.

Should these docs be amended to stipulate that it’s not about what the platform supports, but what Perl is configured for?

@tonycoz
Copy link
Contributor

tonycoz commented Jul 26, 2021

maybe it could also have "but may be larger, depending on how perl is configured."

@khwilliamson
Copy link
Contributor

I think an IV should in fact be as large as required for a pointer to fit in it. Looking at Configure, I don't see anything that forces that. Am I wrong?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants