Difference between revisions of "Break"

From Mesham
Jump to navigationJump to search
m
Line 9: Line 9:
 
== Example ==
 
== Example ==
  
  while (true) { break; };
+
  function void main() {
 +
    while (true) { break; };
 +
};
  
 
Only one iteration of the loop will complete, where it will break out of the body.
 
Only one iteration of the loop will complete, where it will break out of the body.

Revision as of 14:08, 15 April 2013

Syntax

break;

Semantics

Will break out of the current enclosing loop body

Example

function void main() {
   while (true) { break; };
};

Only one iteration of the loop will complete, where it will break out of the body.

Since: Version 0.41b