Sample code (t4.c):
#include <limits.h>
#include <stdio.h>
int main(void)
{
printf("%lld\n", LLONG_MIN);
return 0;
}
Invocation:
$ gcc t4.c && OUT=$(./a.exe) && echo "long long ll = $OUT""ll;" | gcc -xc - -c
<stdin>:1:17: warning: integer constant is so large that it is unsigned
# extra
$ gcc t4.c && OUT=$(./a.exe) && echo "long long ll = $OUT""ll;"
long long ll = -9223372036854775808ll;
Question: why one cannot initialize long long with printed LLONG_MIN? How to fix?