395
edits
(→Anonymous function arguments: more contributions sent by PM) |
Philosopher (talk | contribs) |
||
Line 91: | Line 91: | ||
=== Returning from functions === | === Returning from functions === | ||
In Nasal, functions return implicitly the values of the last expression ( | In Nasal, functions return implicitly the values of the last expression (e.g. "nil" in empty function bodies), you can also add an explicit "return" statement, for example to leave a function early. In addition, it is possible to return values, too. | ||
So, semantically, | So, semantically, these are all equivalent: | ||
var log_message = func {return;} | var log_message = func {return;} |
edits