Hi,

This is just a reminder to avoid a case that occasionally causes warnings for GTK+. On Mac, uint64_t is (I assume) a typedef for unsigned long long. But on Linux 86_64 it's a typedef for unsigned long. This means they have to be printed differently. Using "%llu" to print a uint64_t (presumably) works on Mac, but it causes compiler warnings on Linux. The right way is unfortunately to use "%" PRIu64, which expands to "%llu" on Mac and "%lu" on Linux. There are variants on these macros for many different integer types: http://en.cppreference.com/w/cpp/types/integer

It's verbose, but helps us avoid warnings. And since it's declared in stdint.h/cstdint, if you're using uint64_t then it's already available.

Thanks,

Michael

_______________________________________________
webkit-dev mailing list
webkit-dev@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-dev

Reply via email to