Icon+Unicon/Intro: Difference between revisions

Content added Content deleted
Line 235: Line 235:


=== Procedure Controls ===
=== Procedure Controls ===
====procedure====

Procedures are defined as given below. All procedures have global visibility (there is no nesting). There may be an arbitrary number of arguments. Variable numbers of arguments may be accommodated by specifying one of the arguments as a list.
<lang Icon>procedure name(arg1,arg2,arg3,arg4[])
...
end</lang>

====fail====
====fail====
Causes the the enclosing procedure to terminate without returning value. This is different from returning void or a null value that many other languages do when the code does not return an actual value.
Causes the the enclosing procedure to terminate without returning value. This is different from returning void or a null value that many other languages do when the code does not return an actual value.