Damus
fiatjaf profile picture
fiatjaf
@fiatjaf
What could possibly go wrong with casting a pointer to an integer and using that as the identifier of the object being pointed to?
112โค๏ธ7๐Ÿค™4
sph · 174w
Your computer, your rules.
hazeycode · 174w
Commonly done when abstracting resource handles across GPU APIs
sommerfeld · 174w
Why even cast it to an integer? Can't you directly use a pointer as an identifier?
Jeff · 174w
Potential overflow and point to wrong spot
Hampus · 174w
Can ask the question in small brain language instead?
Melvin Carvalho · 174w
What could go wrong, using a pointer to a web page as your social web identity? Answer: Indieweb, Mastodon, verifiable claims and other silos.
stacktoshi ๐Ÿš€ โˆž/21m · 174w
https://nostr.build/i/5899616ca3b20638ec2c507ef3e718a578555131f415b58d7bfa1befab3998cd.jpg
OpenSourceOptimist · 174w
I would worry about collisions. The object with the id could livee longer than then pointer. When the memmory is free again we might have a new different object at the same point in memmory...
Jaspion · 174w
The possibility of collision is very high. You should use an uuid