PostGIS  2.5.0dev-r@@SVN_REVISION@@
uint64_t zigzag64 ( int64_t  val)

Definition at line 168 of file varint.c.

Referenced by test_zigzag(), and varint_s64_encode_buf().

169 {
170  return val >= 0 ?
171  ((uint64_t)val) << 1 :
172  ((((uint64_t)(-1 - val)) << 1) | 0x01);
173 }

Here is the caller graph for this function: