Skip to content

Commit

Permalink
some expansions in quit(), mostly TODO notes to bring it up to standard
Browse files Browse the repository at this point in the history
  • Loading branch information
Whiteknight committed Feb 2, 2010
1 parent ee102b7 commit 50686c2
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/builtins/quit.pir
@@ -1,5 +1,18 @@
.sub 'quit'
.param int nargout
.param int nargin
.param string mode :optional
.param int has_mode :opt_flag

if has_mode goto check_mode
goto finish_and_die

check_mode:
if mode == "force" goto just_die_already
# TODO: in finish.m, if we call "quit('cancel')" we should stop the exit
# and continue execution from the point after this quit call
finish_and_die:
# TODO: Should look for and execute finish.m if it exists
just_die_already:
die 5, 0
.end

0 comments on commit 50686c2

Please sign in to comment.