Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- Turbo Pascal - <b> goto jump to a label pp 56</b> http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 GOTO                          Jump to a Label                         pp 56

 Syntax:  Goto Target ;

 Type:    N/A

 Form:    Statememt

 Purpose: Jump to a label defined in the current block.

 Notes:   Before use, labels must be declared.  The label declaration must
          be done in the block that the label is used.  The scope of the
          label is that block.

          Labels are best used as a means to get out of a complicated
          loop, rather than a means of entry.  Always Goto the statement
          immediately following the code being exited.



 Usage:
       LABEL
          Target1,           { Labels are separated by commas         }
          Target2;           { Last label terminated with a semicolon }


       BEGIN
          Goto Target1;      { Skip the halt statement                }
          Halt;
          Target1:           { Target label is followed by a colon    }
       END.

See Also: Label

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson