Branch Table - Jump Table Example in PL/I

Jump Table Example in PL/I

PL/I implements a jump table as an array of label variables. These may be initialized in an unusual way by using a subscripted statement label. PL/I label variables are not simply the address of the statement, but usually contain additional information on the state of the code block to which they belong.

declare lab (10) label; declare x fixed binary; goto lab(x); lab(1): /* code for choice 1 */ ; ... lab(2): /* code for choice 2 */ ; ...

Read more about this topic:  Branch Table

Famous quotes containing the words jump and/or table:

    Young men all of us—we’ve got to be. You know why? I’ll give you two good reasons. We jump out of planes, and guys shoot at us.
    Alvah Bessie, Ranald MacDougall, and Lester Cole. Raoul Walsh. Captain Nelson (Errol Flynn)

    When the painted birds laugh in the shade,
    When our table with cherries and nuts is spread:
    Come live, and be merry, and join with me
    To sing the sweet chorus of ‘Ha, ha, he!’
    William Blake (1757–1827)