Skip to content

Return Statement

IsaacShelton edited this page Mar 21, 2022 · 1 revision

Return Statement

Return statements return a value from a function

return my_value

Requirements

In order to return a value from a function, the value must be of the same or similar type as the function’s return type

Deference

All defered statements will be unwound when reaching a return statement, just as if all parent scopes are closed

Clone this wiki locally