Re: [Tinycc-devel] Array BUG

2010-03-15 Thread Daniel Glöckner
On Mon, Mar 15, 2010 at 11:30:51AM +0100, pancake wrote: > this code doesnt compiles with gcc ,the bug is because tcc allows to > compile such expressions? > a.c:10: error: invalid use of array with unspecified bounds > a.c:10: error: invalid use of array with unspecified bounds I have a patch th

Re: [Tinycc-devel] Array BUG

2010-03-15 Thread pancake
this code doesnt compiles with gcc ,the bug is because tcc allows to compile such expressions? can you explain it better? a.c: In function ‘main’: a.c:8: warning: format ‘%X’ expects type ‘unsigned int’, but argument 2 has type ‘int *’ a.c:8: warning: format ‘%X’ expects type ‘unsigned int’, b

[Tinycc-devel] Array BUG

2010-03-14 Thread Alexei
#include int arr[2]; typedef intList[]; typedef List* pList; pList pa; int main(int argc, char **argv) { printf("[0]=%X [1]=%X\n",&arr[0],&arr[1]); pa = &arr; printf("[0]=%X [1]=%X\n",&pa[0],&pa[1]); } Runtime: [0]=4020D0 [1]=4020D4 [0]=4020D0 [1]=4020CC