RETURN - exit current function

 

SYNOPSIS

<RETURN [$value]>


DESCRIPTION
The RETURN statement ends the current function, optionally setting the value of $ret to its given argument. It can be used to exit a function early when some condition or error is met.


DIAGNOSTICS
RETURN sets a return value if an argument is given.


EXAMPLE

<A NAME=update user>
  <SQL MAX=1 "select FullName from passwd where User = $user">
  </SQL>
  <IF $loop eq 0>        <!-- no such $user: quit now -->
    <RETURN>
  </IF>
  ... continue to update the user ...
</A>


CAVEATS
The RETURN statement was added in version 2.1.882300000 19971216.


SEE ALSO
BREAK, exit


Copyright © Thunderstone Software     Last updated: Dec 10 2018
Copyright © 2019 Thunderstone Software LLC. All rights reserved.