Search:

Type: Posts; User: TheBigH

Search: Search took 0.01 seconds.

  1. Replies
    41
    Views
    5,737

    I'm not saying there's no good reasons to spin a...

    I'm not saying there's no good reasons to spin a block of code out into a separate function. I'm just saying that doing it just to avoid goto is not a good reason because, if that's all you're doing,...
  2. Replies
    41
    Views
    5,737

    void func() { while (whatever) { ...

    void func()
    {
    while (whatever) {
    while (something) {
    if (such_and_such)
    return; // <-- no goto needed
    actual_work();
    }
    }
    }
Results 1 to 2 of 2