http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49452
Eric Botcazou <ebotcazou at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ebotcazou at gcc dot | |gnu.org --- Comment #2 from Eric Botcazou <ebotcazou at gcc dot gnu.org> 2011-06-17 16:51:41 UTC --- > NORETURN attribute marked to it but there's no reason why this should be > marked > as NORETURN - surely there is a flow of control that allows control to go out > of the function. > > > x(a) > { > __label__ xlab; > void y(a) > { > void *x = &&llab; > if (a==-1) > goto *x; > if (a==0) > goto xlab; > llab: > y (a-1); > } > y (a); > xlab:; > return a; > } Yes, but this isn't a return, this is a non-local goto so NORETURN is correct.