Hi,
On Tue, 25 Jul 2017, grischka wrote:
uso ewin wrote:
I guess ptrdiff_t should indeed be a long int, but ssize_t should be an
int,
same for intptr_t and uintptr_t should be an unsigned int.
gcc 6.3.0 on win32 (32bits):
test.c:9:14: error: '_Generic' selector of type 'int' is not compatible with
any association
_Generic((ptrdiff_t)0, void*:0);
^
So at least this gcc thinks that ptrdiff_t is of type 'int'.
You can definitely find out with:
% echo __PTRDIFF_TYPE__ | gcc -E
That is the value that tcc must use as well (and then stddef.h is supposed
to simply use that macro, but only to define ptrdiff_t, not any related
types, which shouldn't come from stddef.h at all actually). And yes,
GCCs use 'int' for -m32 normally and 'long int' for -m64.
So the state with commit 28b7c9 was actually correct and was unfixed with
the later 52622c.
Ciao,
Michael.
_______________________________________________
Tinycc-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/tinycc-devel