Andres Freund <andres(at)anarazel(dot)de> writes: > On 2018-10-03 13:18:35 -0400, Tom Lane wrote: >> Having said that, maybe there's a case for changing the type spec >> in only the va_arg() call, and leaving snprintf's related local >> variables as int64. (Is that what you actually meant?) Then, >> if long long really is different from int64, at least we have >> predictable truncation behavior after fetching the value, rather >> than undefined behavior while fetching it.
> Hm. I guess that'd be a bit better, but I'm not sure it's worth it. How > about we simply add a static assert that long long isn't bigger than > int64?