Open main menu
Home
Random
Recent changes
Special pages
Community portal
Preferences
About Wikipedia
Disclaimers
Incubator escapee wiki
Search
User menu
Talk
Dark mode
Contributions
Create account
Log in
Editing
Pointer (computer programming)
(section)
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Value of pointers === In C and C++, even if two pointers compare as equal that doesn't mean they are equivalent. In these languages ''and'' [[LLVM]], the rule is interpreted to mean that "just because two pointers point to the same address, does not mean they are equal in the sense that they can be used interchangeably", the difference between the pointers referred to as their ''provenance''.<ref>{{cite web |last1=Jung |first1=Ralf |title=Pointers Are Complicated II, or: We need better language specs |url=https://www.ralfj.de/blog/2020/12/14/provenance.html}}</ref> Casting to an integer type such as <code>uintptr_t</code> is implementation-defined and the comparison it provides does not provide any more insight as to whether the two pointers are interchangeable. In addition, further conversion to bytes and arithmetic will throw off optimizers trying to keep track the use of pointers, a problem still being elucidated in academic research.<ref>{{cite web |title=Pointers Are Complicated, or: What's in a Byte? |url=https://www.ralfj.de/blog/2018/07/24/pointers-and-bytes.html |last1=Jung|first1=Ralf}}</ref>
Edit summary
(Briefly describe your changes)
By publishing changes, you agree to the
Terms of Use
, and you irrevocably agree to release your contribution under the
CC BY-SA 4.0 License
and the
GFDL
. You agree that a hyperlink or URL is sufficient attribution under the Creative Commons license.
Cancel
Editing help
(opens in new window)