https://github.com/redis/redis/blob/unstable/src/geohash.c#L49 Here the annotation said the pow(2, 32)< 65536, I think it's a mistake, and it should be equal to 4294967296. The reference https://graphics.stanford.edu/~seander/bithacks.html#InterleaveBMN said that got a 32-bit Morton Number, but the geohash.c got a 64-bit number. So I just think it's a copy mistake.

Comment From: oranagra

looks like you're right. wanna make a PR?

Comment From: ResearchingDexter

Yeah, I'm pleased to do it.

Comment From: ResearchingDexter

I just made a PR, Please review that https://github.com/redis/redis/pull/10521