There are cases where goto makes code more readable not less readable. &nbsp;Take nested loops, for example where you need to break out of the outer most loop from inside the inner most loop. &nbsp;Currently there are no semantics to do that cleanly other than using a goto or adding a bunch of arbitrary and unnecessary logic to determine when you are finished.<div>
<br></div><div><div>-Daniel</div><div><br></div><div><div class="gmail_quote">On Tue, Jan 27, 2009 at 1:45 PM, Alex Balashov <span dir="ltr">&lt;<a href="mailto:abalashov@evaristesys.com">abalashov@evaristesys.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><div class="Ih2E3d">Raúl Alexis Betancor Santana wrote:<br>
&gt; El Martes, 27 de Enero de 2009 21:13, Daniel Corbe escribió:<br>
&gt;&gt; You should read <a href="http://kerneltrap.org/node/553/2131" target="_blank">http://kerneltrap.org/node/553/2131</a><br>
&gt;&gt; There&#39;s plenty of cases where goto is justified and certainly branching out<br>
&gt;&gt; into error conditions is one of them. &nbsp;At least on the intel architecture<br>
&gt;&gt; goto typically translates 1:1 to the jmp instruction and is monumentally<br>
&gt;&gt; more efficient than constructing complex and hard to understand loops.<br>
&gt;<br>
&gt; Goto statements should be avoided, it&#39;s not a matter of how much time it takes<br>
&gt; to &quot;goto&quot;, it&#39;s a matter readability of the code<br>
&gt;<br>
<br>
</div>Except where performance really matters.<br>
<br>
In the case of error handling of atypical situations, probably not very<br>
important.<br>
<br>
In the case of something that is inline to the core&#39;s processing of<br>
every request, on the other hand...<br>
<font color="#888888"><br>
--<br>
Alex Balashov<br>
Evariste Systems<br>
Web &nbsp; &nbsp;: <a href="http://www.evaristesys.com/" target="_blank">http://www.evaristesys.com/</a><br>
Tel &nbsp; &nbsp;: (+1) (678) 954-0670<br>
Direct : (+1) (678) 954-0671<br>
Mobile : (+1) (678) 237-1775<br>
</font><div><div></div><div class="Wj3C7c"><br>
_______________________________________________<br>
Kamailio (OpenSER) - Devel mailing list<br>
<a href="mailto:Devel@lists.kamailio.org">Devel@lists.kamailio.org</a><br>
<a href="http://lists.kamailio.org/cgi-bin/mailman/listinfo/devel" target="_blank">http://lists.kamailio.org/cgi-bin/mailman/listinfo/devel</a><br>
<a href="http://lists.openser-project.org/cgi-bin/mailman/listinfo/devel" target="_blank">http://lists.openser-project.org/cgi-bin/mailman/listinfo/devel</a><br>
</div></div></blockquote></div><br></div></div>