Re: Try/Catch
- Posted by Ekhnat0n Feb 18, 2015
- 3879 views
said...
step_5( x )
if error_code != 0 then any action end if
label "cleanup" free_resource( x ) }}}
I would prefer the first option, but right now I am bound to the second.
-Greg
By replacing if error_code != 0 then
by
if error_code then
you will save lots of typing, because IF error_code has any value
it is considered to be TRUE
so if error_code then is a correct statement
Antoine aka Ekhnat0n
Forked into: Please DON'T do that