[Bug c/37755] Mistaken Segmentation fault

2008-10-07 Thread rguenth at gcc dot gnu dot org
--- Comment #4 from rguenth at gcc dot gnu dot org 2008-10-07 07:37 --- As Joseph said. Invalid for -std=c89, worksforme for -std=c99. No changes needed for -std=c1x. -- rguenth at gcc dot gnu dot org changed: What|Removed |Added

[Bug c/37755] Mistaken Segmentation fault

2008-10-06 Thread pinskia at gcc dot gnu dot org
--- Comment #1 from pinskia at gcc dot gnu dot org 2008-10-06 21:25 --- I don't get a seg fault on ppc but I do on x86. It works correctly for the C++ front-end where the array decays into a pointer. The warning is also bogus but it shows what the issue is really. -- pinskia at

[Bug c/37755] Mistaken Segmentation fault

2008-10-06 Thread pinskia at gcc dot gnu dot org
--- Comment #2 from pinskia at gcc dot gnu dot org 2008-10-06 21:25 --- Confirmed. -- pinskia at gcc dot gnu dot org changed: What|Removed |Added

[Bug c/37755] Mistaken Segmentation fault

2008-10-06 Thread joseph at codesourcery dot com
--- Comment #3 from joseph at codesourcery dot com 2008-10-06 21:39 --- Subject: Re: New: Mistaken Segmentation fault On Mon, 6 Oct 2008, charpour at gnet dot gr wrote: printf(%s\n, make_person().name); make_person().name is a non-lvalue array, so it only decays to a pointer