On Friday, 26 July 2013 at 05:12:55 UTC, H. S. Teoh wrote:
On Fri, Jul 26, 2013 at 06:36:21AM +0200, Kagamin wrote:
On Tuesday, 23 July 2013 at 18:14:10 UTC, Ali Çehreli wrote:
>First of all, C does not have exceptions so every single thing
>must be done as two lines:
>
>    err = do_something();
>    goto_finally_if_error(err);

Huh, never seen such pattern in C. I just return error code.

I think what he meant is code like this:

[SNIP]

I have to write code like this every day at work, and it's a royal pain
in the neck.

T

Ditto.

I think it is a pretty common pattern for legacy C programs. Thank god for RAII.

Reply via email to