Goto - Common Usage Patterns

Common Usage Patterns

While overall usage of gotos has been declining, there are still situations in some languages where a goto provides the shortest and most straightforward way to express program's logic (while it's possible to express the same logic without gotos, the equivalent code will be longer and often more difficult to understand).

These situations include: multi-level breaks, resource allocation/deallocation, error handling in C language, computed goto in Perl language.

Read more about this topic:  Goto

Famous quotes containing the words common usage, common, usage and/or patterns:

    The inspired scribbler always has the gift for gossip in our common usage ... he or she can always inspire the commonplace with an uncommon flavor, and transform trivialities by some original grace or sympathy or humor or affection.
    Elizabeth Drew (1887–1965)

    ... a nation to be strong, must be united; to be united, must be equal in condition; to be equal in condition, must be similar in habits and feeling; to be similar in habits and feeling, must be raised in national institutions as the children of a common family, and citizens of a common country.
    Frances Wright (1795–1852)

    Girls who put out are tramps. Girls who don’t are ladies. This is, however, a rather archaic usage of the word. Should one of you boys happen upon a girl who doesn’t put out, do not jump to the conclusion that you have found a lady. What you have probably found is a lesbian.
    Fran Lebowitz (b. 1951)

    The ninety percent of human experience that does not fit into established narrative patterns falls into oblivion.
    Mason Cooley (b. 1927)