Hi Gus,
For the sake of completeness, if you're wondering why gcc requires an integer type, please check the C standard:This is because your code finally ends up with this expression: (void*)ptr>> 4 and gcc doesn't allow the shift operation to be performed on pointer types. A possible solution to your problem could be the following code:
6.5.7 Bitwise shift operators [...] Constraints Each of the operands shall have integer type. Best regards, Andre-Marcel