GNU Info

Info Node: (librep.info)Function Exits

(librep.info)Function Exits


Next: Cleanup Forms Prev: Catch and Throw Up: Non-Local Exits
Enter node , (file) or (file)node

Function Exits
..............

   `librep' has no explicit `return' statement, as found in most other
languages. Where a value has to returned from a function before the
function would normally exit, a `catch'/`throw' pair may be used.

   For example:

     (defun foo (x y)
       (catch 'return
          (when (= x 2)
            (throw 'return nil))
          ...


automatically generated by info2www version 1.2.2.9