{
...
switch(foo % 4){
case 0:
func1();
goto end;
case 1:
func2();
goto end;
...
}
end:
return value;
}
It is not that ugly (such constructions are common in kernel sources)
and is optimized by gcc : a return is appended in lieu of the jump.
Regards,
Regis "HPReg" Duchesne - Engineering Student at ***** ******** *****
www http://www.via.ecp.fr/~regis/
(O o) I use Linux & 3Com (1135 KB/s over 10Mb/s ethernet)
--.oOO--(_)--OOo.-----------------------------------------------------------