From f48f8c7585dde1b9b0ca02d4ae877cd234d45d4f Mon Sep 17 00:00:00 2001 From: Jakub Vrana Date: Wed, 7 Jan 2009 13:34:18 +0000 Subject: [PATCH] Document goto git-svn-id: https://svn.php.net/repository/phpdoc/en/trunk@272953 c90b9560-bf6c-de11-be94-00142212c4b1 --- appendices/reserved.xml | 4 +- language/control-structures.xml | 3 +- language/control-structures/goto.xml | 66 ++++++++++++++++++++++++++++ 3 files changed, 70 insertions(+), 3 deletions(-) create mode 100644 language/control-structures/goto.xml diff --git a/appendices/reserved.xml b/appendices/reserved.xml index 0227d8048e..7988adbe0f 100755 --- a/appendices/reserved.xml +++ b/appendices/reserved.xml @@ -1,5 +1,5 @@ - + List of Reserved Words @@ -124,7 +124,7 @@ global - goto (as of PHP 5.3) + goto (as of PHP 5.3) diff --git a/language/control-structures.xml b/language/control-structures.xml index 0a8b062bf8..37a003deaa 100644 --- a/language/control-structures.xml +++ b/language/control-structures.xml @@ -1,5 +1,5 @@ - + Control Structures @@ -34,6 +34,7 @@ &language.control-structures.include; &language.control-structures.require-once; &language.control-structures.include-once; + &language.control-structures.goto; diff --git a/language/control-structures/goto.xml b/language/control-structures/goto.xml new file mode 100644 index 0000000000..8461c7a237 --- /dev/null +++ b/language/control-structures/goto.xml @@ -0,0 +1,66 @@ + + + + + <literal>goto</literal> + + The goto operator can be used to jump to other + instruction in the program. The target place is specified by the label and a + colon and goto is followed by that label. + + + + <literal>goto</literal> example + + +]]> + + &example.outputs; + + + + + + + + The goto operator is available since PHP 5.3. + + + + + It is not allowed to jump into loop or switch statement. Fatal error is + issued in such case. + + + + + +