From: Julian S. <js...@ac...> - 2008-04-24 22:23:02
|
On Friday 25 April 2008 00:08, Christoph Bartoschek wrote: > Am Donnerstag, 24. April 2008 schrieb Julian Seward: > > Let me ask first, does anyone know of any reason why the test > > program (which segfaults) could be declared to be invalid C, > > and so gcc's code could then be said to be valid? > > > > Also, it's worth checking the problem is reproducible on the > > latest stable gcc (4.3.0). Filing bug reports on older gccs is > > imo pretty much pointless. > > I've tested it with 4.3.0 and it segfaults. The program is not pure C > because it uses linux specific things, but it should be valid. Ok, good. The real reason for my question (is it valid C?) is that the GCC folks have amongst them a good collection of language lawyers. They are very good at thinking up reasons why programs like the test case are somehow not exactly compliant with the C standards, and so it is ok for gcc to produce apparently-broken code as we see. So I'm just trying to get the test case as well sanity-checked as we can, before sending it off to gcc-land. J |