|
|
|
|
|
by int_19h
3459 days ago
|
|
Wouldn't it be very unusual for an environment to not do wraparound? I mean, on assembler level, pointers are just integers, and pretty much everything does wraparound arithmetics on those these days. But, so far as I can see, this case (allocating at the very end of address space) is the only one where wraparound would matter for pointers. And what would be the other option? If it's saturation, then your one-past-the-end pointer for the array at the end of address space would compare equal to pointer to last element... |
|
Now, runtimes are increasingly adopting address randomization, which can change the rules about this, depending on what you are doing.