Specifying 64-bit unsigned integer literals on 64-bit data models

You should use <cstdint> / <stdint.h>, if you have it. This will give you:

  • uint64_t is an unsigned integer type which is 64 bits in size
  • UINT64_C() is a macro for creating constants of the type uint64_t, by having the macro append the proper suffix.

Leave a Comment