return
no way to compare when less than two revisions
Differences
This shows you the differences between two versions of the page.
— | return [2006/08/29 20:18] (current) – created - external edit 127.0.0.1 | ||
---|---|---|---|
Line 1: | Line 1: | ||
+ | ======Synopsis: | ||
+ | [[return]] | ||
+ | [[return]] //< | ||
+ | |||
+ | ======Description: | ||
+ | [[Return]] terminates processing of the current | ||
+ | * [[alias command|alias]] (command or function) call, | ||
+ | * [[defer]] command, | ||
+ | * [[exec command|exec]] callback, | ||
+ | * [[load]], | ||
+ | * [[on]] hook callback, | ||
+ | * [[queue]] command, | ||
+ | * [[timer]] command, | ||
+ | * [[wait|wait -cmd]] callback, | ||
+ | * [[wait|wait %proc -cmd]] callback, or | ||
+ | * {...} math operator. | ||
+ | |||
+ | You may optionally supply a return value which will be assigned to the | ||
+ | // | ||
+ | * The body of the {...} math operator | ||
+ | * [[on|on ?type]] handlers | ||
+ | * Any alias function call. | ||
+ | |||
+ | Using the [[return]] command outside of one of the above contexts yields | ||
+ | an error and has no effect. | ||
+ | |||
+ | ======Examples: | ||
+ | alias square (arg) return ${arg * arg} | ||
+ | eval echo $square(5) | ||
+ | |||
+ | will output | ||
+ | |||
+ | 25 | ||
+ | |||
+ | ======History====== | ||
+ | The [[return]] command first appeared in EPIC4pre1.031. | ||
+ | |||
return.txt · Last modified: 2006/08/29 20:18 by 127.0.0.1