News for hackers. Stuff that matters.
Re:You Can't Always Hash Pointers in C by qb45 on Tuesday May 31, 2016 @07:33AM (#11805922)
> int* can be the same number with the lowest 2 bits always 0.

And now you have to right-shift int pointers on every dereference for some dubious benefit. It's easier and more efficient to make pointer arithmetic and casting painful.

Re:You Can't Always Hash Pointers in C by adrianratnapala on Friday June 03, 2016 @05:52PM (#11833550)
No, you left-shift them on every cast.

And is someone type-puns using a union, they get a thing four times samller than they might have expected. Stil it is totally well behaved in a hash.