goto a no-go?

Dicebot public at dicebot.lv
Tue Oct 1 04:26:53 PDT 2013


> // ...
> if (word.length == 1) goto FormatOutput;
>
> // if word.length > 1, some extra work has to be done
> // initialize some variables, parse, do some processing etc.
>
> FormatOutput:
>  // .....
>
> return output;

Have never felt need to use `goto` since got familiar with 
`scope(something)` : http://dpaste.dzfl.pl/ca40b3b6

;)


More information about the Digitalmars-d mailing list